|
ServerInstallation
This page explains how to setup your own OpenID Server using JOID.
IntroductionThere are two pieces required to run the server:
DependenciesYou'll need the following in your classpath along with joid.jar.
web.xmlAdd the servlet from above to your web.xml: <servlet>
<servlet-name>loginServlet</servlet-name>
<servlet-class>org.verisign.joid.server.OpenIdServlet</servlet-class>
<init-param>
<param-name>endPointUrl</param-name>
<param-value>http://localhost:8080/joid/login</param-value>
<description>Change this to your endpoint url.</description>
</init-param>
<init-param>
<param-name>loginPage</param-name>
<param-value>login.jsp</param-value>
<description>Change this to your login page where the user enters their username and password and/or
approves the authentication for the site.
</description>
</init-param>
<init-param>
<param-name>storeClassName</param-name>
<param-value>org.verisign.joid.server.MemoryStore</param-value>
<description>Specify the className for your Store implementation.
</description>
</init-param>
<init-param>
<param-name>userManagerClassName</param-name>
<param-value>org.verisign.joid.server.MemoryUserManager</param-value>
<description>Specify the className for your UserManager implementation.
</description>
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>loginServlet</servlet-name>
<url-pattern>/login</url-pattern>
</servlet-mapping>
Be sure to modify the init-params in the web.xml to the appropriate values. Login PageYou'll need some way for a user to login/authenticate themselves. There is a sample in /examples/server/login.jsp that simply asks the user to login and accept the Realm that is asking to authenticate. Running the Sample AppThe sample app is both a consumer and a server. You can deploy it by dropping /out/joid.war into your TOMCAT_HOME/webapps directory. Then surf to http://localhost:8080/joid/ to try it out. |
Sign in to add a comment
typo (I think): There are --two-- three pieces required to run the server: