Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trusted proxies can be read from config file #2168

Closed
jtuttle opened this issue May 14, 2021 · 0 comments · Fixed by #2175
Closed

Trusted proxies can be read from config file #2168

jtuttle opened this issue May 14, 2021 · 0 comments · Fixed by #2175

Comments

@jtuttle
Copy link
Contributor

jtuttle commented May 14, 2021

Create a new class Conjur::ConjurConfig using the Anyway Config gem and configure it to:

  • read from /etc/conjur/config/conjur.yml
  • read environment variables prefixed with CONJUR_
  • fall back to TRUSTED_PROXIES for backwards compatibility
  • default to empty string if no values are configured

Update Conjur::TrustedProxyFilter to read the trusted proxies value from the ConjurConfig object.

Logging

  • INFO to Rails log when config object created "Loaded config from "
  • WARNING to Rails log when no config file present "No config file found at "

Unit Tests

  • update the Conjur::TrustedProxyFilter unit tests to use the ConjurConfig object
  • create new unit tests for Conjur::ConjurConfig to test the precedence behavior
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant