EJBCA installation on Windows

Source: Internet
Author: User
Tags informix sybase jboss mysql command line

In order to do EJBCA packaging test, in my own computer installed a, but in the domestic development of the introduction is too little, and some are just some silly installation introduction, this is introduced in the Windows installation process, (described below on the Linux Red Hat), some are also on the Internet to see, Some of the more critical areas are pointed out below:

Recommend a relatively good URL: https://sourceforge.net/p/ejbca/discussion/

EJBCA Installation

EJBCA is a full-featured open source CA system software based on the Java EE Technology and provides a powerful, high-performance, component-based CA. EJBCA is flexible and platform independent, can be used independently, and can be integrated with any Java EE application.

Features: Online A lot of do not say.



List of software used (I passed it on Csdn myself):

J2se6

Jce_policy-6.zip

JDK 1.6 Update 12 and JCE Unlimited Strength jurisdiction Policy Files 6 Release candidate
http://download.csdn.net/detail/liweifengwf/7391507


Jboss:

Jboss-5.0.1.ga-jdk6 (Note please download jboss-5.0.1.ga-jdk6.zip) This 120 trillion is too big to pass.

Go to the official website for half a day do not know where to download, so went to the sourceforge.

Http://downloads.sourceforge.net/jboss/jboss-5.0.1.GA-jdk6.zip?use_mirror=jaist


EJBCA:

Ejbca_4_0_10

http://download.csdn.net/detail/liweifengwf/7391473

or official website: http://www.ejbca.org/download.html

Ant:

apache-ant-1.8.4
http://download.csdn.net/detail/liweifengwf/7391449

Mysql:

MySQL 5.1
Http://dev.mysql.com/downloads/mysql/5.1.html

Mysql-connector-java-5.1.7.zip
http://download.softagency.net/MySQL/Downloads/Connector-J/


Installation steps:

1, installation j2se6;

There is the decompression jce_policy, and will be decompressed Jce_policy-1_4_2\jce in the Local_policy.jar and Us_export_policy.jar copy, covering C:\Program files\ file with the same name in Java\j2re1.4.2_02\lib\security. .

2, install MySQL. The user name password is "root". Run the MySQL command line in the Start menu, enter the password "root", and create an empty database EJBCA, the command behavior "CREATE database EJBCA;". Then quit the command-line tool, and he will build his own needs without worrying about it.

3, decompression EJBCA, JBoss, ant to the C packing directory.

4. mysql jar file,

Copy the Mysql-connector-java-5.1.7-bin.jar in the Mysql-connector-java-5.1.7.zip to the%jboss_home%/server/default/lib directory.

5. Set environment variables. (This does not need to elaborate, remember that after the configuration of the cmd window closed in open)

Java_home = C:/Program Files/java/jdk1.6.0_12

Jboss_home = C:/jboss-5.0.1.ga

Ant_home = c:/apache-ant-1.7.1

Ant_opts =-xmx640m

PATH =%java_home%/bin;%jboss_home%/bin;%ant_home%/bin;

Classpath=%java_home%/lib/dt.jar;%java_home%/lib/tools.jar;%java_home%/lib;

6, run JBoss Run.bat. After JBoss is fully booted, Access http://localhost:8080 in the browser and the JBoss Welcome page indicates that JBoss is running successfully. Then be sure to stop JBoss run.

7. Configure EJBCA

Save%ejbca_home%/conf/ejbca.properties.sample Copy as%ejbca_home%/conf/ejbca.properties

Be sure to change the ejbca.properties file under the red place

The following red part of this file:

# to prevent accidental runs of tests or deploying the wrong thing in a production

# Environment, we could prevent this by setting the variable to either "Ca" or "OCSP"

Ejbca.productionmode=ca

#ejbca. PRODUCTIONMODE=OCSP

Save%ejbca_home%/conf/web.properties.sample, copy to%ejbca_home%/conf/web.properties

Save%ejbca_home%/conf/database.properties.sample Copy as%ejbca_home%/conf/database.properties

Edit Database.properties as follows (mainly the color of the place below the "#" lines in the original file is ' # ', the modification is to remove the ' # ')

#-------------Database Configuration------------------------

# Jndi Name of the DataSource to use in deployment descriptors of EJBS.
# default:ejbcads
#datasource. jndi-name=ejbcads

# Prefix for the jndi name of the DataSource to use in deployment descriptors of EJBS.
# JBoss requires ' java:/' as prefix, while Weblogic does not want anything ('), and Glassfish wants jdbc/
# Oracle usually uses jdbc/as well.
# for Websphere use jdbc/.
# default:java:/
#datasource. jndi-name-prefix=java:/
#datasource. jndi-name-prefix=
#datasource. jndi-name-prefix=jdbc/

# Weblogic in combination with Oracle Requires special handling of LONG/BLOB columns
# If, and only if, is using Weblogic and Oracle, uncomment the row Below.
# Use Oracleblob in Weblogic 8.x and blobs in Weblogic 9.x
# note:this setting are not needed in Weblogic 9.2. Leave it commented out.
# default: 
#[email protected] Blob

# the database name selected for deployment, used to copy XDoclet merge files.
# all supported databases is defined below, others can easily be added
# See the document Doc/howto/howto-database.txt for database specifics and tips and tricks.
# default:hsqldb
database.name=mysql
#database. name=postgres
# database.name=mssql2000
#database. name=oracle
#database. name=sapdb
#database. name=sybase
Span style= "COLOR: #333333" > #database. Name=informix
#database. Name=derby
#database. NAME=DB2

# The DataSource mapping selected for deployment.
# The Java EE server needs to being configured with the appropriate datasource mapping.
# for JBoss This maps to a setting in Standardjbosscmp-jdbc.xml and must match the database chosen above.
# All supported mappings is defined below, others can easily be added
# default:hypersonic SQL
Datasource.mapping=mysql
#datasource. Mapping=postgresql 7.2
#datasource. Mapping=postgresql 8.0
#datasource. Mapping=ms SQLSERVER2000
#datasource. Mapping=oracle8
#datasource. mapping=oracle9i
#datasource. mapping=sapdb
#datasource. Mapping=sybase
#datasource. mapping=informix92
#datasource. Mapping=informixdb
#datasource. Mapping=derby
#datasource. MAPPING=DB2

# Database Connection URL.
# This is the URL of used to connect to the database, used to configure a new DataSource in JBoss.
# Default:jdbc:hsqldb:${jboss.server.data.dir}${/}hypersonic${/}localdb
#database. URL=JDBC:MYSQL://127.0.0.1:3306/EJBCA
Database.url=jdbc:mysql://127.0.0.1:3306/ejbca?characterencoding=utf-8
#database. URL=JDBC:POSTGRESQL://127.0.0.1/EJBCA
#database. URL=JDBC:MICROSOFT:SQLSERVER://LOCALHOST:1433;DATABASENAME=EJBCA
#database. URL=JDBC:ORACLE:THIN:@127.0.0.1:1521:EJBCA
#database. url=jdbc:datadirect:oracle://127.0.0.1:1521; SID=EJBCA
#database. url=jdbc:informix-sqli://127.0.0.1:1525/ejbca:informixserver=mydbservername;dbdate=dmy4/;
#database. Url=jdbc:derby://127.0.0.1/ejbca;create=true
#database. URL=JDBC:DB2://127.0.0.1:50000/EJBCA

# JDBC driver classname.
# the EE server needs to being configured with the appropriate JDBC driver for the selected Database
# Default:org.hsqldb.jdbcDriver
database.driver=com.mysql.jdbc.driver
#database. driver=org.postgresql.driver
# Database.driver=com.microsoft.jdbc.sqlserver.sqlserverdriver
# Database.driver=oracle.jdbc.driver.oracledriver
#database. driver= Com.ddtek.jdbc.oracle.OracleDriver
#database. driver= Com.informix.jdbc.IfxDriver
#database. driver= Org.apache.derby.jdbc.ClientDriver
#database. driver= Com.ibm.db2.jcc.DB2Driver

# Database username.
# Default:sa (works with HSQLDB)
#database. USERNAME=EJBCA
#database. Username=postgres
Database.username=root

# Database password.
# Default: (blank works with HSQLDB)
#database. PASSWORD=EJBCA
#database. Password=postgres
Database.password=root

The configuration is finished, then follow the steps below to walk on the line;

8.cmd to%ejbca_home% directory, run Ant Bootstrap for EJBCA compilation (if the old version needs to copy the Ejbca.ear file under C:\ejbca_4_0_10\dist to C + + after compiling Jboss-5.1.0.ga\server\default\deploy directory, the new version will be compiled automatically).


The total time appears to indicate that the compilation is complete.


9, do not switch directories, typing start run.bat, start the JBoss console (will be a separate window, this jboss boot directory does not close).




The started in tiime appears to indicate that the JBoss boot is complete.


10, do not switch directories , typing ant install for EJBCA installation (the installation will generate P12 files, such as no such file, check the previous steps for missing items). (note) in JBoss startup Window If the JCE cannot authenticate the provider BC error, put%ejbca_home%/lib/bc*. The jar is copied to the%jboss_home%server/default/lib. such as:


When installing, notice the log of JBoss Startup window, which is more clear when the error occurs.


11. Press CTRL + C to stop JBoss.

12, do not switch directories , the ant deploy, EJBCA deployment.


The total time EJBCA installation is complete.


13, go to%ejbca_home%/p12 under, install SUPERADMIN.P12 certificate, password for "EJBCA".

to modify the default certificate password: (modify default password in %ejbca_home%\CONF\WEB.PROPERTIES\SUPERADMIN.PASSWORD=EJBCA)

14, the installation is successful.

CMD to the%ejbca_home% directory, run Run.bat to start JBoss.

In the IE Address bar, typing https://localhost:8443/ejbca/administrator appears in the Certificate selection dialog box, after selecting the Superadmin certificate, the Administration console page appears:


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.