Sunday, March 7, 2010

How WebLogic Server Locates Trust when using own SSL certificate

It is necessary to provide JVM property -Dweblogic.security.SSL.trustedCAKeyStore in all scripts connecting to weblogic SSL port.
Other option is to add server SSL certificate into cacerts trust keystore inside WLS installation.

Default trust key store is located in WL_HOME/server/lib and also in JDK
find . -name cacerts
./jrockit_160_14_R27.6.5-32/jre/lib/security/cacerts
./wlserver_10.3/server/lib/cacerts
./jdk160_14_R27.6.5-32/jre/lib/security/cacerts



export JAVA_OPTIONS="-Dweblogic.security.SSL.trustedCAKeyStore=/app/cert/ServerTrust.jks ${JAVA_OPTIONS}"


This is defined is Oracle® Fusion Middleware Securing Oracle WebLogic
Server 11g Release 1 (10.3.1) , Chpt 11, Configuring identity and
trust



WebLogic Server uses the following algorithm when it loads its trusted
CA certificates:

1.  I<span style="font-weight:bold;">f the keystore is specified by the
-Dweblogic.security.SSL.trustedCAkeystore command-line argument,</span> load
the trusted CA certificates from that keystore.
2. Else if the keystore is specified in the configuration file
(config.xml), load trusted CA certificates from the specified
keystore. If the server is configured with DemoTrust, trusted CA
certificates will be loaded from the WL_HOME\server\lib\DemoTrust.jks
and the JDK cacerts keystores.
3. Else if the trusted CA file is specified in the configuration
file (config.xml), load trusted CA certificates from that file (this
is only for compatibility with 6.x SSL configurations).
4.Else load trusted CA certificates from <span style="font-weight:bold;">WL_HOME\server\lib\cacerts</span> keystore.



10.3.2
http://download.oracle.com/docs/cd/E15523_01/web.1111/e13707/identity_trust.htm#i1202187

10.3.1
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13707/identity_trust.htm#i1202182

10.3
http://download.oracle.com/docs/cd/E12840_01/wls/docs103/secmanage/identity_trust.html#wp1183754

Monday, February 8, 2010

Understanding Domain Configuration for Oracle WebLogic Server

Understanding Domain Configuration for Oracle WebLogic Server
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13716/toc.htm


security/SerializedSystemIni.dat

servers/server-name/security/boot.properties



Provide User Credentials to Start and Stop Servers
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13708/overview.htm#i1068520

Creating Boot Identity Files for Managed Servers
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13708/overview.htm#i1068975

Friday, January 29, 2010

Running WLST from Ant

Running WLST from Ant


http://download.oracle.com/docs/cd/E12839_01/web.1111/e13715/using_wlst.htm#insertedID6


<taskdef name="wlst" classname="weblogic.ant.taskdefs.management.WLSTTask" classpathref="wl.ant.classpath"/>



    <target name="create-domain-using-wlst">
<echo message=" Creating domain using WLST ... "/>
<wlst debug="true" failOnError="true" fileName="./wlst/createDomain.py">
</wlst>
</target>

Monday, January 25, 2010

Create domain using WLST

Documentation root
http://download.oracle.com/docs/cd/E12839_01/index.htm

Creating Domain Templates Using the Domain Template Builder
http://download.oracle.com/docs/cd/E12839_01/web.1111/e14139/toc.htm

Prepare Scripts and Files with Replacement Variables
http://download.oracle.com/docs/cd/E12839_01/web.1111/e14139/tempbuild.htm#insertedID14


Creating Domains Using WLST Offline
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13715/domains.htm#i1018386

Creating Templates and Domains Using the Pack and Unpack Commands
http://download.oracle.com/docs/cd/E12839_01/web.1111/e14144/toc.htm




WLST command reference
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13813/quick_ref.htm#insertedID0


readTemplate
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13813/reference.htm#i1029278


writeDomain
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13813/reference.htm#i1003687

adminServerName = "AdminServer"
adminServerUrl = "t3://localhost:7001"
adminUser = "weblogic"
adminPassword = "weblogic123"

domainName = "DaVeDomain"
domainHome = "/home/dave/" + domainName

templateName = "/app/bea/user_templates/" + domainName + ".jar"

print "Reading template " + templateName

readTemplate(templateName)

set("Name",domainName)

ls()

cd("/Security/" + domainName + "/User/" + adminUser)
cmo.setPassword(adminPassword)


writeDomain(domainHome)

closeTemplate()

startServer(adminServerName,
domainName,
adminServerUrl,
adminUser,
adminPassword,
domainHome,
block="true")

connect(adminUser, adminPassword, adminServerUrl)

ls()

shutdown()

exit()



startMyWeblogic.sh

DOMAIN_NAME="@DOMAIN_NAME"

DOMAIN_HOME="@DOMAIN_HOME"

ADMIN_URL="http://@SERVER_HOST:@SERVER_PORT"


. ${DOMAIN_HOME}/bin/setDomainEnv.sh

Weblogic deployment

Deploying Applications to Oracle WebLogic Server
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13702/toc.htm


Controlling Deployment File Copying with Staging Modes
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13702/deploy.htm#i1027041

WLST deploy
http://download.oracle.com/docs/cd/E12839_01/web.1111/e13813/reference.htm#i1024284


deploy(appName, path, [targets], [stageMode], [planPath], [options])