include::../description.adoc[] include::../ask-yourself.adoc[] include::../recommended.adoc[] == Sensitive Code Example https://docs.spring.io/spring-social-twitter/docs/1.1.0.RELEASE/reference/htmlsingle/[Spring-social-twitter] secrets can be stored inside a xml file: ---- ---- == Compliant Solution In https://docs.spring.io/spring-social-twitter/docs/1.1.0.RELEASE/reference/htmlsingle/[spring social twitter], retrieve secrets from environment variables: ---- @Configuration public class SocialConfig implements SocialConfigurer { @Override public void addConnectionFactories(ConnectionFactoryConfigurer cfConfig, Environment env) { cfConfig.addConnectionFactory(new TwitterConnectionFactory( env.getProperty("twitter.consumerKey"), env.getProperty("twitter.consumerSecret"))); } } ---- include::../see.adoc[] ifdef::env-github,rspecator-view[] ''' == Implementation Specification (visible only on this page) include::../message.adoc[] include::../parameters.adoc[] ''' == Comments And Links (visible only on this page) include::../comments-and-links.adoc[] endif::env-github,rspecator-view[]