﻿<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/"><channel><title>BlogJava-interbase-文章分类-EJBCA</title><link>http://www.blogjava.net/interbase/category/3755.html</link><description>Java与RFID中间件</description><language>zh-cn</language><lastBuildDate>Fri, 02 Mar 2007 20:18:34 GMT</lastBuildDate><pubDate>Fri, 02 Mar 2007 20:18:34 GMT</pubDate><ttl>60</ttl><item><title>EJBCA User guide</title><link>http://www.blogjava.net/interbase/articles/15002.html</link><dc:creator>Java与RFID中间件</dc:creator><author>Java与RFID中间件</author><pubDate>Sat, 08 Oct 2005 09:10:00 GMT</pubDate><guid>http://www.blogjava.net/interbase/articles/15002.html</guid><wfw:comment>http://www.blogjava.net/interbase/comments/15002.html</wfw:comment><comments>http://www.blogjava.net/interbase/articles/15002.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.blogjava.net/interbase/comments/commentRss/15002.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/interbase/services/trackbacks/15002.html</trackback:ping><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要: User guideAbout Security Upgrade Quick start guide Prerequisites Configure Install Running optional tests After the installation Administrating EJBCA Creating more CAs ...&nbsp;&nbsp;<a href='http://www.blogjava.net/interbase/articles/15002.html'>阅读全文</a><img src ="http://www.blogjava.net/interbase/aggbug/15002.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/interbase/" target="_blank">Java与RFID中间件</a> 2005-10-08 17:10 <a href="http://www.blogjava.net/interbase/articles/15002.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>我自己写的一个EJBCA安装的文档</title><link>http://www.blogjava.net/interbase/articles/15001.html</link><dc:creator>Java与RFID中间件</dc:creator><author>Java与RFID中间件</author><pubDate>Sat, 08 Oct 2005 09:05:00 GMT</pubDate><guid>http://www.blogjava.net/interbase/articles/15001.html</guid><wfw:comment>http://www.blogjava.net/interbase/comments/15001.html</wfw:comment><comments>http://www.blogjava.net/interbase/articles/15001.html#Feedback</comments><slash:comments>1</slash:comments><wfw:commentRss>http://www.blogjava.net/interbase/comments/commentRss/15001.html</wfw:commentRss><trackback:ping>http://www.blogjava.net/interbase/services/trackbacks/15001.html</trackback:ping><description><![CDATA[<FONT face=Verdana>
<P><FONT face="verdana, arial, helvetica" size=2><BR>一 准备工作(本文档中的路径均为我自己在安装时的路径)<BR><BR>使用EJBCA集成的数据库,所有可以不安装数据库<BR>安装JDK1.4.*,设置JAVA_HOME=C:\j2sdk1.4.2_02;设置classpath=C:\j2sdk1.4.2_02\lib;设置path=C:\j2sdk1.4.2_02\bin;<BR>安装ANT,下载安装包,解压缩到安装路径,设置ANT_HOME=C:\apache-ant-1.6.1;设置path=C:\apache-ant-1.6.1\bin;(一般ANT的安装没有什么问题的)<BR>安装JBOSS,下载安装包,解压缩到安装路径,设置JBOSS_HOME=C:\jboss-3.2.5,启动JBOSS(运行JBOSS_HOME\bin\run.bat),用<A href="http://localhost:8080访问,出现JBOSS的相关信息,这表示JBOSS安装成功/" target=_blank>http://localhost:8080访问,出现JBOSS的相关信息,这表示JBOSS安装成功/</A><BR>到下载JDK的地方下载一个 "Unlimited Strength Jurisdiction Policy Files",解压缩之后得到一个JCE文件夹,将里面的两个文件复制到系统默认得jre环境的lib\security下面覆盖原来的两个文件.(我安装时将这两个文件复制到JAVA_HOME\jre\lib\security 下面install时通不过,放到了C:\Program Files\Java\j2re1.4.2_02\lib\security 下面 install才顺利进行)<BR><BR>装好这些之后,最好重启机器,让ejbca找得到JBOSS_HOME<BR><BR>二 ant build.xml 过程<BR>运行 cmd 到ejbca 的安装目录下,运行ant<BR><BR>C:\ejbca&gt;ant (ant 会根据 ejbca 的 build.xml文件,创建 编译 打包 复制文件)<BR>Buildfile: build.xml<BR><BR>init:<BR>[mkdir] Created dir: C:\ejbca\tmp\classes<BR>[mkdir] Created dir: C:\ejbca\dist<BR><BR>compile:<BR>[javac] Compiling 462 source files to C:\ejbca\tmp\classes<BR>[copy] Copying 466 files to C:\ejbca\src\java<BR><BR>apply.war:<BR>[mkdir] Created dir: C:\ejbca\tmp\publicweb\apply.war<BR>[copy] Copying 20 files to C:\ejbca\tmp\publicweb\apply.war<BR>[copy] Copying 43 files to C:\ejbca\tmp\publicweb\apply.war\WEB-INF\classe<BR><BR>[jar] Building jar: C:\ejbca\dist\apply.war<BR><BR>status.war:<BR>[mkdir] Created dir: C:\ejbca\tmp\publicweb\status.war<BR>[copy] Copying 1 file to C:\ejbca\tmp\publicweb\status.war<BR>[copy] Copying 25 files to C:\ejbca\tmp\publicweb\status.war\WEB-INF\class<BR>s<BR>[jar] Building jar: C:\ejbca\dist\status.war<BR><BR>webdist.war:<BR>[mkdir] Created dir: C:\ejbca\tmp\publicweb\webdist.war<BR>[copy] Copying 7 files to C:\ejbca\tmp\publicweb\webdist.war<BR>[copy] Copying 47 files to C:\ejbca\tmp\publicweb\webdist.war\WEB-INF\clas<BR>es<BR>[jar] Building jar: C:\ejbca\dist\webdist.war<BR><BR>ca.jar:<BR>[mkdir] Created dir: C:\ejbca\tmp\ca\ca.jar<BR>[copy] Copying 435 files to C:\ejbca\tmp\ca\ca.jar<BR>[jar] Building jar: C:\ejbca\dist\ca.jar<BR><BR>log.jar:<BR>[mkdir] Created dir: C:\ejbca\tmp\log.jar<BR>[copy] Copying 10 files to C:\ejbca\tmp\log.jar<BR>[copy] Copying 23 files to C:\ejbca\tmp\log.jar<BR>[jar] Building jar: C:\ejbca\dist\log.jar<BR><BR>authorization.jar:<BR>[mkdir] Created dir: C:\ejbca\tmp\authorization.jar<BR>[copy] Copying 9 files to C:\ejbca\tmp\authorization.jar<BR>[copy] Copying 90 files to C:\ejbca\tmp\authorization.jar<BR>[jar] Building jar: C:\ejbca\dist\authorization.jar<BR><BR>hardtoken.jar:<BR>[mkdir] Created dir: C:\ejbca\tmp\hardtoken.jar<BR>[copy] Copying 9 files to C:\ejbca\tmp\hardtoken.jar<BR>[copy] Copying 64 files to C:\ejbca\tmp\hardtoken.jar<BR>[jar] Building jar: C:\ejbca\dist\hardtoken.jar<BR><BR>keyrecovery.jar:<BR>[mkdir] Created dir: C:\ejbca\tmp\keyrecovery.jar<BR>[copy] Copying 10 files to C:\ejbca\tmp\keyrecovery.jar<BR>[copy] Copying 28 files to C:\ejbca\tmp\keyrecovery.jar<BR>[jar] Building jar: C:\ejbca\dist\keyrecovery.jar<BR><BR>ra.jar:<BR>[mkdir] Created dir: C:\ejbca\tmp\ra.jar<BR>[copy] Copying 11 files to C:\ejbca\tmp\ra.jar<BR>[copy] Copying 94 files to C:\ejbca\tmp\ra.jar<BR>[jar] Building jar: C:\ejbca\dist\ra.jar<BR><BR>adminweb.war:<BR>[mkdir] Created dir: C:\ejbca\tmp\adminweb.war<BR>[copy] Copying 95 files to C:\ejbca\tmp\adminweb.war<BR>[copy] Copying 13 files to C:\ejbca\tmp\adminweb.war\WEB-INF\classes<BR>[jar] Building jar: C:\ejbca\dist\adminweb.war<BR><BR>ca.ear:<BR>[mkdir] Created dir: C:\ejbca\tmp\ca\ear<BR>[copy] Copying 1 file to C:\ejbca\tmp\ca\ear\ear<BR>[copy] Copying 7 files to C:\ejbca\tmp\publicweb\publicwebroot.war<BR>[jar] Building jar: C:\ejbca\tmp\ca\ear\ear\publicwebroot.war<BR>[copy] Copying 10 files to C:\ejbca\tmp\ca\ear\ear<BR>[copy] Copying 7 files to C:\ejbca\tmp\ca\ear\ear\lib<BR>[jar] Building jar: C:\ejbca\dist\ejbca-ca.ear<BR><BR>admin.jar:<BR>[mkdir] Created dir: C:\ejbca\tmp\adminjar<BR>[copy] Copying 2 files to C:\ejbca\tmp\adminjar<BR>[copy] Copying 217 files to C:\ejbca\tmp\adminjar<BR>[jar] Building jar: C:\ejbca\admin.jar<BR><BR>build:<BR><BR>BUILD SUCCESSFUL<BR>Total time: 30 seconds<BR><BR>在这个过程中 会在EJBCA下面生成tmp 和 dist 文件夹以及一个admin.jar(在install时用得着),据我自己分析,ejbca本身所有的东西都放在tmp文件夹里了,ejbca\tmp\java\classes下面有所有.class 文件,dist用来放各个部分打的包.<BR>(有一点我不明白的是为什么要把admin.jar放在下面根目录下面,而不把部署文件ejbca-ca.ear放在这个下面)<BR><BR>三 ant deploy 过程<BR>C:\ejbca&gt;ant deploy<BR>Buildfile: build.xml<BR><BR>init:<BR><BR>compile:<BR><BR>apply.war:<BR><BR>status.war:<BR><BR>webdist.war:<BR><BR>ca.jar:<BR><BR>ra.jar:<BR><BR>adminweb.war:<BR><BR>log.jar:<BR><BR>hardtoken.jar:<BR><BR>keyrecovery.jar:<BR><BR>authorization.jar:<BR><BR>ca.ear:<BR><BR>admin.jar:<BR><BR>deploy:<BR>[copy] Copying 1 file to C:\jboss-3.2.2RC1_tomcat-4.1.24\server\default\dep<BR>loy<BR>[copy] Copying C:\ejbca\dist\ejbca-ca.ear to C:\jboss-3.2.2RC1_tomcat-4.1.2<BR>4\server\default\deploy\ejbca-ca.ear<BR><BR>BUILD SUCCESSFUL<BR>Total time: 6 seconds<BR><BR>这时你在JBOSS_HOME\server\default\deploy下面发现多了个ejbca-ca.ear文件,ejbca-ca.ear 是上一步的ca.ear:时生成的,这个文件里包含了ant 时打的所有的包<BR>启动JBOSS 你会发现有ejbca-ca.ear部署成功的信息,在启动JBOSS的过程中,JBOSS会对ejbca-ca.ear作一些处理<BR><BR>四 install 过程<BR><BR>C:\ejbca&gt;install<BR>Welcome to EJBCA Installation<BR>This script acts as a wizard helping you with the installation of your Certifica<BR>te Authority.<BR><BR>Before the installation will begin make sure of the following preparations have<BR>been done:<BR><BR>1. The EJBCA application is deployed to the application server. ('ant deploy')<BR><BR>2. You run this installation with access to administrative privileges.(你的登录机器的身份必须具有administrator身份)<BR><BR>Is these requirements meet (Yes/No) :Yes<BR><BR><BR>This installation will create a first administrative CA. This CA will be used to<BR>create the first<BR>superadministrator and for the SSL server certificate of administrative web serv<BR>er.<BR><BR>When the administrative web server have been setup you can create other CA:s and<BR>administrators.<BR><BR>Please enter the short name for the CA.<BR>This is only used for administrative purposes,<BR>avoid spaces or odd characters (Ex 'AdminCA1') :shaoshao(这是给CA命一个common name&lt;CN&gt; , 一个好记的名字,可以自己取)<BR>Enter the Distinguished Name of the CA. This is used in the CA certificate to di<BR>stinguish the CA. (Ex 'CN=AdminCA1,O=PrimeKey Solutions AB,C=SE') :CN=shaoshao,<BR>O=PrimeKey Solutions AB,C=SE(这是CA 的DN,我想CN应该与前面一样,)<BR>Enter the keysize in bits of the CA, only digits. (Ex '2048') : 2048<BR>Enter the validity in days for the CA, only digits (Ex '3650') :3650<BR>Enter the policy id of the CA. Policy id determine which PKI policy the CA uses.<BR><BR>Type your policy id or use '2.5.29.32.0' for any policy or 'NO' for no policy at<BR>all.<BR>(Ex '2.5.29.32.0') :202.197.125.190(输入自己机器的IP,也可以使用通用的2.5.29.32.0)<BR>(以上都是有关创建CA的一些信息,CA会有一个根证书SuperAdmin)<BR><BR>Now for some information required to set up the administration web interface.(为EJBCA 的 administr<BR>ative web gui 创建一个 ssl 服务器端证书 )<BR><BR>Please enter the computer name of CA server. (Ex 'caserver.primekey.se') :hs(输入自己机器的名字)<BR>Enter the Distinguished Name of the SSL server certificate used by the administr<BR>ative web gui<BR>(Ex 'CN=caserver.primekey.se,O=PrimeKey Solutions AB,C=SE') :CN=huangshao,O=PrimeKey Solutions AB,C=SE(ssl服务器端证书的DN,CN应该是可以随便取的,在通过<A href="https://localhost:8443/ejbca/adminweb/访问时" target=_blank>https://localhost:8443/ejbca/adminweb/访问时</A> 可以查看此证书的信息)<BR>Enter a good password for the super administrators keystore. Please remember thi<BR>s one:12345678(打开install.cmd可以看到默认的JAVACACERTPASSWD=changeit;将SuperAdmin.p12导入浏览器时输入的就是这个密码)<BR><BR><BR>You have entered the following data :<BR><BR><BR>CA short name : shaoshao<BR>Distinguished Name CA : CN=shaoshao,O=PrimeKey Solutions AB,C=SE<BR>Keysize of the CA : 2048<BR>Validity in days for the CA : 3650<BR>Policy id of the CA : 202.197.125.190<BR>Computer name of CA server : hs<BR>Distinguished Name of the SSL server certificate : CN=huangshao,O=PrimeKey Solut<BR>ions AB,C=SE<BR>Password for the super administrators keystore : 12345678<BR>Is this correct ( Yes/No/Exit ) :Y<BR><BR>The installation will now start, please wait .....<BR><BR><BR>Initializing CA<BR>Generating rootCA keystore:<BR>DN: CN=shaoshao,O=PrimeKey Solutions AB,C=SE<BR>Keysize: 2048<BR>Validity (days): 3650<BR>Policy ID: 202.197.125.190<BR>Initalizing Temporary Authorization Module.<BR>Creating CA...<BR>CAId for created CA: -1912334509<BR>-Created and published initial CRL.<BR>CA initialized<BR>(此过程中 会 创建CA ,会生成CA的证书 ,会初始化user状态 会发布CRL 会把证书添加到KEYSTORE中等等)<BR><BR>Setup of Administration Web Interface have started, this will take a minute to c<BR>omplete ....<BR><BR>keytool错误： java.lang.Exception: 别名 &lt;EJBCA-CA&gt; 不存在<BR><BR>认证已添加至keystore中<BR><BR>The installation is now complete.<BR>Proceed with the following steps in order to start administrating EJBCA.<BR><BR>1. Restart the application server.<BR>2. Import the p12/superadmin.p12 file in your browser.<BR>3. Go to the following URL: <A href="https:///" target=_blank>https://</A>&lt;computername&gt;:8443/ejbca/adminweb<BR>4. And now your are all set to start using EJBCA.<BR><BR>If you are interested in professional support of EJBCA and PKI related question<BR>s,<BR>please contact PrimeKey Solutions AB, Sweden at <A href="mailto:ejbca@primekey.se">ejbca@primekey.se</A> or <A href="http://www.primeke/" target=_blank>http://www.primeke/</A><BR>y.se for more information.<BR><BR>在这个阶段会创建CA 创建两个证书(在ejbca下面会有p12/superadmin.p12生成) install的具体有那些操作可以打开ejbca\install.cmd看看<BR>(我这里有个问题是: 老是出现keytool错误： java.lang.Exception: 别名 &lt;EJBCA-CA&gt; 不存在,是不是第一次装ejbca都会出现这个错误?)<BR><BR>五 访问administration page<BR>重新启动JBOSS ,将p12/superadmin.p12导入浏览器,然后通过<A href="https://localhost:8443/ejbca/adminweb" target=_blank>https://localhost:8443/ejbca/adminweb</A> 就可以访问了<BR><BR>我在安装的过程中,出现了很多问题,有时候install成功了,但是<A href="https://localhost:8443/ejbca/adminweb" target=_blank>https://localhost:8443/ejbca/adminweb</A> 访问时就是打不开页面,也不知道什么原因,只好把JDK,JBOSS,EJBCA重新安装了很多次,重启了很多次机器之后才成功的.<BR><BR>其中有错误的地方,请大家一定要指出来!</FONT></P></FONT><img src ="http://www.blogjava.net/interbase/aggbug/15001.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/interbase/" target="_blank">Java与RFID中间件</a> 2005-10-08 17:05 <a href="http://www.blogjava.net/interbase/articles/15001.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item></channel></rss>