<!-- settings for the Graph-API -->
<facebook.app.id>NOT_SET</facebook.app.id>
<facebook.app.secret>NOT_SET</facebook.app.secret>
- <facebook.app.salt>NOT_SET</facebook.app.salt>
<facebook.app.canvas>NOT_SET</facebook.app.canvas>
<!-- settings for the Apache Commons Http-Client -->
<httpclient.timeout.connection>60000</httpclient.timeout.connection>
-import java.math.BigInteger;
import javax.inject.Inject;
import javax.sql.DataSource;
import org.apache.http.HttpRequestFactory;
-import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Scope;
@Inject
SignInAdapter signInAdapter;
- @Value("${facebook.app.secret}")
- String secret;
- @Value("${facebook.app.salt}")
- String salt;
-
/**
* Add a {@link FacebookConnectionFactory} to the configuration.
new JdbcUsersConnectionRepository(
dataSource,
connectionFactoryLocator,
- Encryptors.text(
- secret,
- String.format("%08x", new BigInteger(1, salt.getBytes()))
- )
+ Encryptors.noOpText()
);
repository.setConnectionSignUp(connectionSignUp);
return repository;
facebook.app.id=@facebook.app.id@
facebook.app.secret=@facebook.app.secret@
-facebook.app.salt=@facebook.app.salt@
facebook.app.canvas=@facebook.app.canvas@
server.port: 8443