Profile name#233
Conversation
Expose WithAwsProfileName on the builder and serialize AwsProfileName for the native JSON config. Document in README; add unit tests (InternalsVisibleTo for ToJson assertions). Made-with: Cursor
Add serde AwsProfileName to shared config; plumb profile through KMS, Secrets Manager, and DynamoDB builders; shared aws_sdk_load for credential profiles. Update Node bindings and READMEs; extend config_apply_env tests. Made-with: Cursor
* main: fix(ffi,cobhan,session): zero decrypted plaintext before deallocation (godaddy#216) test(types): verify to_json_fast / from_json_fast produce serde-compatible JSON (godaddy#220)
Document the optional AWS credentials profile on the builder. Refresh dotnet README tables after merge with main. Made-with: Cursor
Match PreferredRegion and other ConfigOptions fields in this section. Made-with: Cursor
Align wording length with neighboring optional fields. Made-with: Cursor
Keep pub mod declarations contiguous; place non-exported helper before re-exports. Made-with: Cursor
|
Reviewed the PR end-to-end. The core change ( Blocking — markdown auto-formatter damageA formatter (looks like Prettier) was run over Four hyperlinks are now wrapped in backticks, so they render as inline code instead of links:
The PR Checklist in List-item continuation indent was stripped — numbered list children went from 3-space (correct under Trailing newlines were removed from all three files. Please revert the unrelated reformatting (or split it into a separate PR with the formatter configured to leave inline-code-in-links and task lists alone). Should fix
Nits
|
Markdown formatter damage: - Revert CONTRIBUTING.md, asherah-dotnet/README.md, asherah-py/README.md to main (the auto-formatter wrapped four hyperlinks in backticks breaking them, dropped the [ ] task-list markers from the PR Checklist, destroyed list-item continuation indent, and stripped trailing newlines). - Re-add the legitimate doc additions on top: WithAwsProfileName row in the .NET builder table and AwsProfileName row in the Python config table. Legacy AwsKms path: - Thread aws_profile_name through AwsKms::new and AwsKms::new_async (was previously hard-coded to None in the shared loader call). - AwsKmsBuilder gains a profile_name(...) builder method. - aws_kms_from_env keeps the env-var contract by passing None — the SDK's default credential chain already honors AWS_PROFILE. API duplication collapsed: - Drop the *_with_profile sibling methods in kms_aws_envelope.rs (new_single_with_profile, new_multi_with_profile, new_single_async_with_profile, new_multi_async_with_profile) and kms_secrets_manager.rs (new_with_profile, new_async_with_profile). - The original methods now take aws_profile_name: Option<&str> directly. Update all callers (builders.rs, integration tests, example, kms_aws_envelope unit test). Wording consistency: - index.d.ts said `~/.aws/config`; .NET XML doc said `~/.aws/credentials`. Unify on the .NET wording (typically credentials, with the SDK honoring both). Test cleanup: - Drop unused `using GoDaddy.Asherah;` in AsherahConfigTests.cs (the test namespace already has GoDaddy.Asherah as an implicit ancestor).
|
Pushed commits to address the review feedback. Specifically: Markdown formatter damage (blocking): reverted
Legacy API duplication collapsed: dropped the Python README config table: added an Wording consistency: Test cleanup: removed the unused Local verification: full lint sweep green, .NET test suite green (124 + 30 each TFM), Python (50), Node (full roundtrip + 4 cache-bound), Go (full suite), Ruby (40). I also merged latest |
Summary
Adds optional
AwsProfileNameto shared JSON config (serde) and threads it through Rust AWS SDK loading for KMS, DynamoDB, and Secrets Manager..NET
AsherahConfig/ builder:WithAwsProfileName, serialized asAwsProfileNameInternalsVisibleTofor internalToJson)WithAwsProfileName; README updates merged from mainTesting
scripts/test.sh --unit/ workspace tests as applicabledotnet testonasherah-dotnet/GoDaddy.Asherah.Encryption.slnx