added crypto configuration file

pull/105/merge
Justin Richer 2012-06-19 16:25:13 -04:00
parent a38dc0ce29
commit 94256d95a1
1 changed files with 33 additions and 0 deletions

View File

@ -0,0 +1,33 @@
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
<bean id="defaultKeystore" class="org.mitre.jwt.signer.service.impl.KeyStore">
<constructor-arg name="location" value="classpath:keystore.jks" />
<constructor-arg name="password" value="changeit" />
</bean>
<bean id="defaultsignerService"
class="org.mitre.jwt.signer.service.impl.JwtSigningAndValidationServiceDefault">
<property name="signers">
<map>
<entry key="rsa1">
<bean id="rsaSigner" class="org.mitre.jwt.signer.impl.RsaSigner">
<property name="algorithm" value="RS256" />
<property name="keystore" ref="defaultKeystore" />
<property name="alias" value="rsa" />
<property name="password" value="changeit" />
</bean>
</entry>
<entry key="hmac1">
<bean id="hmacSigner" class="org.mitre.jwt.signer.impl.HmacSigner">
<property name="algorithm" value="HS256" />
<property name="passphrase" value="changeit" />
</bean>
</entry>
</map>
</property>
</bean>
</beans>