Repository navigation
Allow secrets to be provided from a file or environment variable - #5177
Merged
Merged
Conversation
sisuresh
commented
Mar 12, 2026
sisuresh
force-pushed
the
secrets
branch
2 times, most recently
from
March 13, 2026 18:23
693a0d1 to
87cb7bc
Compare
sisuresh
marked this pull request as ready for review
March 14, 2026 00:19
Contributor
There was a problem hiding this comment.
Pull request overview
Adds support for resolving sensitive config values (currently NODE_SEED) from external secret sources, primarily via $FILE: references, and documents / tests the behavior.
Changes:
- Introduce
util/SecretManagerfor resolving$FILE:-prefixed config values with permission checks and whitespace trimming. - Update config parsing to allow
NODE_SEEDto be read from a$FILE:reference and reject such references on public network config. - Add unit tests and update the example config documentation for
$FILE:usage.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 9 comments.
Show a summary per file
| File | Description |
|---|---|
| src/util/SecretManager.h | New API for resolving config secrets (e.g., $FILE:). |
| src/util/SecretManager.cpp | Implements file-based secret resolution and permission validation. |
| src/main/Config.cpp | Uses SecretManager when parsing NODE_SEED; rejects external secrets on pubnet. |
| src/main/test/ConfigTests.cpp | Adds tests for secret resolution and config integration. |
| docs/stellar-core_example.cfg | Documents $FILE: usage for NODE_SEED. |
You can also share your feedback on Copilot code review. Take the survey.
dmkozh
approved these changes
Mar 31, 2026
sisuresh
enabled auto-merge
April 1, 2026 18:33
dmkozh
approved these changes
Apr 1, 2026
dmkozh
approved these changes
Apr 1, 2026
auto-merge was automatically disabled
April 1, 2026 20:43
Pull request was closed
sisuresh
enabled auto-merge
April 1, 2026 20:44
marta-lokhova
approved these changes
Apr 1, 2026
This was referenced Apr 10, 2026
github-merge-queue Bot
pushed a commit
that referenced
this pull request
Apr 10, 2026
# Description Extension on #5177 <!--- Describe what this pull request does, which issue it's resolving (usually applicable for code changes). ---> # Checklist - [ ] Reviewed the [contributing](https://github.com/stellar/stellar-core/blob/master/CONTRIBUTING.md#submitting-changes) document - [ ] Rebased on top of master (no merge commits) - [ ] Ran `clang-format` v8.0.0 (via `make format` or the Visual Studio extension) - [ ] Compiles - [ ] Ran all tests - [ ] If change impacts performance, include supporting evidence per the [performance document](https://github.com/stellar/stellar-core/blob/master/performance-eval/performance-eval.md)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Resolves #1316
Checklist
clang-formatv8.0.0 (viamake formator the Visual Studio extension)