Basic authentication on standalone OC4J 9.0.4

I am trying to configure basic authentication on standalone OC4J 9.0.4 (Jdev 10g) but nothing happens, I am still able to get to the page. My deployment descriptor files:
* principals.xml
<principals>
     <groups>
          <groups>
               <description>AQ Demo Group</description>
               <group name="aqgroup" />
          </groups>
     </groups>
     <users>
          <user username="foo" password="bar">
               <description>no description</description>
               <group-membership group="aqgroup" />
          </user>
     </users>
</principals>
* web.xml
<security-constraint>
          <display-name>AQDemo Security Constraint</display-name>
          <web-resource-collection>
          <web-resource-name>MySecureArea</web-resource-name>
          <url-pattern>*</url-pattern>
          </web-resource-collection>
          <auth-constraint>
          <role-name>role1</role-name>
          </auth-constraint>
     </security-constraint>
     <login-config>
          <auth-method>BASIC</auth-method>
     </login-config>
     <security-role>
          <role-name>role1</role-name>
     </security-role>
* orion-application.xml
<?xml version = '1.0' encoding = 'windows-1250'?>
<!DOCTYPE orion-application PUBLIC "-//Evermind//DTD J2EE Application runtime 1.2//EN" "http://xmlns.oracle.com/ias/dtds/orion-application.dtd">
<orion-application>
<data-sources path="./data-sources.xml"/>
<security-role-mapping name="role1">
     <group name="aqgroup" />
</security-role-mapping>
</orion-application>
* application.xml
<?xml version = '1.0' encoding = 'windows-1250'?>
<!DOCTYPE application PUBLIC "-//Sun Microsystems, Inc.//DTD J2EE Application 1.3//EN" "http://java.sun.com/dtd/application_1_3.dtd">
<application>
<display-name>aqdemo</display-name>
<module>
<web>
<web-uri>aqdemo.war</web-uri>
<context-root>aqdemoroot</context-root>
</web>
<security-role-mapping name="role1">
     <group name="aqgroup" />
</security-role-mapping>
</module>
</application>

I commented out the jazn element now and I am prompted for username and password, so that part works. However, it's still not recognizing my user and I am only able to get “Not authorized” message. I'm guessing it has something to do with the security role mapping. This is how my files look now:
* principals.xml
<?xml version="1.0"?>
<!DOCTYPE principals PUBLIC "//ORACLE//DTD OC4J Principals 9.04//EN" "http://xmlns.oracle.com/ias/dtds/principals-9_04.dtd">
<principals>
     <groups>
          <group name="administrators">
               <description>administrators</description>
               <permission name="administration" />
          </group>
          <group name="aqgroup">
               <description>AQ Demo Group</description>
          </group>
          <group name="guests">
               <description>guests</description>
          </group>
          <group name="users">
               <description>users</description>
          </group>
     </groups>
     <users>
          <user username="jasmina" password="babu">
               <description>no description</description>
               <group-membership group="aqgroup" />
          </user>
          <user username="user" password="456" deactivated="true">
               <description>The default user</description>
               <group-membership group="guests" />
               <group-membership group="users" />
          </user>
          <user username="pwForSSL" password="123456" deactivated="true">
               <description>Password for database user Scott</description>
          </user>
          <user username="SCOTT" password="TIGER">
               <description>no description</description>
               <group-membership group="users" />
          </user>
          <user username="foo" password="bar">
               <description>no description</description>
               <group-membership group="aqgroup" />
          </user>
          <user username="pwForScott" password="TIGER" deactivated="true">
               <description>Password for database user Scott</description>
          </user>
          <user username="anonymous" password="">
               <description>The default guest/anonyomous user</description>
               <group-membership group="guests" />
          </user>
          <user username="admin" password="admin">
               <description>The default administrator</description>
               <group-membership group="administrators" />
               <group-membership group="guests" />
               <group-membership group="users" />
          </user>
          <user username="pwForSystem" password="manager" deactivated="true">
               <description>Password for database user Scott</description>
          </user>
     </users>
</principals>
* web.xml
<web-app>
<security-constraint>
<display-name>AQDemo Security Constraint</display-name>
<web-resource-collection>
<web-resource-name>MySecureArea</web-resource-name>
<url-pattern>*</url-pattern>
</web-resource-collection>
<auth-constraint>
<role-name>role1</role-name>
</auth-constraint>
</security-constraint>
<login-config>
<auth-method>BASIC</auth-method>
</login-config>
<security-role>
<role-name>role1</role-name>
</security-role>
</web-app>
* orion-application.xml
<orion-application>
<data-sources path="./data-sources.xml"/>
<security-role-mapping name="role1">
<group name="aqgroup"/>
</security-role-mapping>
</orion-application>
* application.xml (location: OC4JHOME/applications/myapp/META-INF/)
<application>
<display-name>aqdemo</display-name>
<module>
<principals location="./principals.xml"/>
<web>
<web-uri>aqdemo.war</web-uri>
<context-root>aqdemoroot</context-root>
</web>
</module>
</application>

Similar Messages

  • Can anyone provide me the examples of OC4j basic authentication

    Can anyone provide me the examples or links of OC4j basic authentication?
    Thanks in advance

    Can anyone provide me the examples or links of OC4j basic authentication?
    Thanks in advance

  • Compilation error when deploying EAR file on standalone OC4J...

    Hi All,
    I am getting the following error when trying to deploy an EAR File describing a web service from the Jdeveloper IDE to the stanalone OC4J server instance.
    ==========================================================
    Uploading file JavaWebServiceEmp-GetDates-WS.ear ...
    Application Deployer for JavaWebServiceEmp-GetDates-WS STARTS.
    Copy the archive to C:\Lester\Testing\JDev10.1.3\oc4j\j2ee\home\applications\JavaWebServiceEmp-GetDates-WS.ear
    Initialize C:\Lester\Testing\JDev10.1.3\oc4j\j2ee\home\applications\JavaWebServiceEmp-GetDates-WS.ear begins...
    Unpacking JavaWebServiceEmp-GetDates-WS.ear
    Done unpacking JavaWebServiceEmp-GetDates-WS.ear
    Unpacking WebServices.war
    Done unpacking WebServices.war
    Initialize C:\Lester\Testing\JDev10.1.3\oc4j\j2ee\home\applications\JavaWebServiceEmp-GetDates-WS.ear ends...
    Starting application : JavaWebServiceEmp-GetDates-WS
    Initializing ClassLoader(s)
    Initializing EJB container
    Loading connector(s)
    Starting up resource adapters
    Initializing EJB sessions
    Committing ClassLoader(s)
    Initialize WebServices begins...
    Initialize WebServices ends...
    Started application : JavaWebServiceEmp-GetDates-WS
    Binding web application(s) to site default-web-site begins...
    Binding WebServices web-module for application JavaWebServiceEmp-GetDates-WS to site default-web-site under context root JavaWebServiceEmp-GetDates-context-root
    Operation failed with error:
    Error compiling :C:\Lester\Testing\JDev10.1.3\oc4j\j2ee\home\applications\JavaWebServiceEmp-GetDates-WS\WebServices: compilation error occurred
    Deployment failed
    Elapsed time for deployment: 1 minute, 50 seconds
    ==========================================================
    Please could somebody help me out with this? Basically I am not able to understand how to deploy the EAR file created under the MyWork folder under jdeveloper\jdev to the applications folder of j2ee\home. I am new to both EAR deployment as well as web services and would like to get a good understanding of the working of a web service which includes SOAP components and the like.
    Any help with regards to building and deploying a web service on standalone OC4J would be appreciated. Thanks a lot.

    Initially I followed the following steps to start up OC4J:-
    Settings :-
    1) Jdeveloper is setup under C:\Lester\Testing as Jdev10.1.3 folder
    2) I downloaded the extended oc4j zip folder and unzipped it under a new folder oc4j at the location C:\Lester\Testing\Jdev10.1.3
    Steps followed to run oc4j and deploy application
    1) Setup a standalone oc4j from the jdeveloper ide giving C:\Lester\Testing\Jdev10.1.3\oc4j as the root folder for oc4j.
    2) While doing step 1 added password and deployed it. Changed server.xml under C:\Lester/Testing/JDev10.1.3/oc4j/j2ee/home/config
    to include the following:-
    <shared-library name="global.libraries" version="1.0" library-compatible="true">
    <code-source path="C:\Lester/Testing/JDev10.1.3/oc4j/j2ee/home/applib"/>
    </shared-library>
    AND
    <java-compiler name="javac" in-process="false" options="-J-Xmx1024m -encoding UTF8" bindir="C:\Jdeveloper\jdk" extdirs="C:\Jdeveloper/jdk" />
    3) Opened a command prompt and went to the location C:\Lester\Testing\JDev10.1.3\oc4j\j2ee\home and ran the following command:-
    --> java -jar oc4j.jar
    4) Deployment: Then I deployed my primewebservice application from command prompt at C:\Lester\Smart Cylinder\Example code\prime\PrimeNumberService>
    using:-
    --> java -jar C:\Lester/Testing/JDev10.1.3/oc4j/j2ee/home/admin.jar ormi://172.20.13.164:8888 oc4jadmin welcome -deploy -file PrimeNumberService.ear -deploymentName DocStyleWebService
    5) Web Binding: Then I bound my primewebservice application from command prompt at C:\Lester\Smart Cylinder\Example code\prime\PrimeNumberService>
    using:-
    --> java -jar C:\Lester/Testing/JDev10.1.3/oc4j/j2ee/home/admin.jar ormi://172.20.13.164:8888 oc4jadmin welcome -bindWebApp DocStyleWebService PrimeNumberService_web http-web-site /docws
    6) Steps 4 and 5 went through without error.
    7) However when trying to access the web service using the following link I get the standard HTTP 404 (Page not found) error:-
    http://localhost:8888/docws/prime
    This was before I tried deploying the web service through jdeveloper IDE.
    I had tried the document web service given at the following link:-
    http://www.oracle.com/technology/sample_code/tech/java/codesnippet/webservices/docservice/index.html
    from the web services how to links
    http://www.oracle.com/technology/sample_code/tech/java/codesnippet/webservices/index.html
    Please could somebody help me out? Also periodically I recieve the ojc.exe not found error when trying to deploy an application using jdeveloper ide. There are two conflicting jdeveloper versions one comes with this exe and one without.
    Message was edited by:
    Lester N

  • Has anyone had a WebService running on standalone OC4J 101300 / 101310

    I am trying to run the most basic of webservices on these containers - what was achieved within minutes on IBM WAS 6.0, JBoss 4.0 and WLS 9.1 is just not getting possible with this release of the container!
    Initially thought it was a deployment / code issue - but have been consistently able to take the same WSDL and generate the WebService (and deploy) on other containers except OC4J. The same service runs successfully within JDev embedded OC4J.
    Using JDeveloper, I was able to generate both top-down and bottom-up services. Neither got deployed - either through uploading the EAR file, ANT build file, JDeveloper deploy to connections etc...
    Even tried changed entries in the server.xml and the default-web-site.xml file - but it is of no use.
    No extra libraries were added - same results were obtained even with a fresh install of the container in this environment: WinXP Pro + JDK 1.5.2_09 + OC4J 101300 / 101310.
    All these come back with the same error:
    06/11/16 20:01:15 SEVERE: ProgressObjectImpl.reportError java.lang.ClassCastExce
    ption: com.sun.org.apache.xerces.internal.dom.DeferredElementNSImploracle.oc4j.a
    dmin.jmx.shared.exceptions.InternalException: java.lang.ClassCastException: com.
    sun.org.apache.xerces.internal.dom.DeferredElementNSImpl
    at oracle.oc4j.admin.jmx.shared.deploy.NotificationUserData.<init>(Notif
    icationUserData.java:107)
    at oracle.oc4j.admin.internal.Notifier.reportError(Notifier.java:429)
    at oracle.oc4j.admin.internal.DeployerBase.execute(DeployerBase.java:123
    at oracle.oc4j.admin.jmx.server.mbeans.deploy.OC4JDeployerRunnable.doRun
    (OC4JDeployerRunnable.java:52)
    at oracle.oc4j.admin.jmx.server.mbeans.deploy.DeployerRunnable.run(Deplo
    yerRunnable.java:81)
    at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExec
    utor.java:819)
    at java.lang.Thread.run(Thread.java:595)
    Caused by: oracle.oc4j.admin.internal.DeployerException: java.lang.ClassCastExce
    ption: com.sun.org.apache.xerces.internal.dom.DeferredElementNSImpl
    at oracle.oc4j.admin.internal.WebApplicationBinder.bindWebApp(WebApplica
    tionBinder.java:214)
    at oracle.oc4j.admin.internal.WebApplicationBinder.bindWebApp(WebApplica
    tionBinder.java:96)
    at oracle.oc4j.admin.internal.ApplicationDeployer.bindWebApp(Application
    Deployer.java:541)
    at oracle.oc4j.admin.internal.ApplicationDeployer.doDeploy(ApplicationDe
    ployer.java:197)
    at oracle.oc4j.admin.internal.DeployerBase.execute(DeployerBase.java:93)
    ... 4 more
    Caused by: java.lang.ClassCastException: com.sun.org.apache.xerces.internal.dom.
    DeferredElementNSImpl
    at oracle.j2ee.ws.server.deployment.WebServiceEndpoint.writeRuntimeXml(W
    ebServiceEndpoint.java:660)
    at oracle.j2ee.ws.server.deployment.WebServiceEndpoint.writeXML(WebServi
    ceEndpoint.java:616)
    at com.evermind.xml.XMLUtils.writeAll(XMLUtils.java:136)
    at oracle.j2ee.ws.server.deployment.WebService.writeEndpoints(WebService
    .java:382)
    at oracle.j2ee.ws.server.deployment.WebService.writeXML(WebService.java:
    374)
    at com.evermind.xml.XMLUtils.writeAll(XMLUtils.java:136)
    at oracle.j2ee.ws.server.deployment.WebServicesDescriptor.writeWebServic
    es(WebServicesDescriptor.java:447)
    at oracle.j2ee.ws.server.deployment.WebServicesDescriptor.writeOrionXML(
    WebServicesDescriptor.java:426)
    at oracle.j2ee.ws.server.deployment.WebServicesDescriptor.writeOrionConf
    ig(WebServicesDescriptor.java:401)
    at com.evermind.server.J2EEComponent.getDeploymentContent(J2EEComponent.
    java:403)
    at com.evermind.server.J2EEComponent.storeDeployment(J2EEComponent.java:
    494)
    at com.evermind.server.http.WrapperClassGenerator.generateWebServiceArts
    (WrapperClassGenerator.java:93)
    at com.evermind.server.http.HttpApplication.generateWebServiceArtifacts(
    HttpApplication.java:8403)
    at com.evermind.server.http.HttpApplication.populateLoaderWithWebService
    sDeploymentCache(HttpApplication.java:5465)
    at com.evermind.server.http.HttpApplication.populateLoader(HttpApplicati
    on.java:5394)
    at com.evermind.server.http.HttpApplication.initClassLoader(HttpApplicat
    ion.java:5333)
    at com.evermind.server.http.HttpApplication.<init>(HttpApplication.java:
    645)
    at com.evermind.server.ApplicationStateRunning.getHttpApplication(Applic
    ationStateRunning.java:428)
    at com.evermind.server.Application.getHttpApplication(Application.java:5
    12)
    at com.evermind.server.http.HttpSite$HttpApplicationRunTimeReference.cre
    ateHttpApplicationFromReference(HttpSite.java:1975)
    at com.evermind.server.http.HttpSite$HttpApplicationRunTimeReference.<in
    it>(HttpSite.java:1894)
    at com.evermind.server.http.HttpSite.addHttpApplication(HttpSite.java:15
    91)
    at oracle.oc4j.admin.internal.WebApplicationBinder.bindWebApp(WebApplica
    tionBinder.java:206)
    ... 8 more
    2006-11-16 20:01:15.642 ERROR java.lang.ClassCastException: com.sun.org.apache.x
    erces.internal.dom.DeferredElementNSImpl
    2006-11-16 20:01:15.764 NOTIFICATION Application UnDeployer for tanfsandbox COMP
    LETES.
    06/11/16 20:01:15 WARNING: DeployerRunnable.run java.lang.ClassCastException: co
    m.sun.org.apache.xerces.internal.dom.DeferredElementNSImploracle.oc4j.admin.inte
    rnal.DeployerException: java.lang.ClassCastException: com.sun.org.apache.xerces.
    internal.dom.DeferredElementNSImpl
    at oracle.oc4j.admin.internal.DeployerBase.execute(DeployerBase.java:126
    at oracle.oc4j.admin.jmx.server.mbeans.deploy.OC4JDeployerRunnable.doRun
    (OC4JDeployerRunnable.java:52)
    at oracle.oc4j.admin.jmx.server.mbeans.deploy.DeployerRunnable.run(Deplo
    yerRunnable.java:81)
    at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExec
    utor.java:819)
    at java.lang.Thread.run(Thread.java:595)
    Caused by: java.lang.ClassCastException: com.sun.org.apache.xerces.internal.dom.
    DeferredElementNSImpl
    at oracle.j2ee.ws.server.deployment.WebServiceEndpoint.writeRuntimeXml(W
    ebServiceEndpoint.java:660)
    at oracle.j2ee.ws.server.deployment.WebServiceEndpoint.writeXML(WebServi
    ceEndpoint.java:616)
    at com.evermind.xml.XMLUtils.writeAll(XMLUtils.java:136)
    at oracle.j2ee.ws.server.deployment.WebService.writeEndpoints(WebService
    .java:382)
    at oracle.j2ee.ws.server.deployment.WebService.writeXML(WebService.java:
    374)
    at com.evermind.xml.XMLUtils.writeAll(XMLUtils.java:136)
    at oracle.j2ee.ws.server.deployment.WebServicesDescriptor.writeWebServic
    es(WebServicesDescriptor.java:447)
    at oracle.j2ee.ws.server.deployment.WebServicesDescriptor.writeOrionXML(
    WebServicesDescriptor.java:426)
    at oracle.j2ee.ws.server.deployment.WebServicesDescriptor.writeOrionConf
    ig(WebServicesDescriptor.java:401)
    at com.evermind.server.J2EEComponent.getDeploymentContent(J2EEComponent.
    java:403)
    at com.evermind.server.J2EEComponent.storeDeployment(J2EEComponent.java:
    494)
    at com.evermind.server.http.WrapperClassGenerator.generateWebServiceArts
    (WrapperClassGenerator.java:93)
    at com.evermind.server.http.HttpApplication.generateWebServiceArtifacts(
    HttpApplication.java:8403)
    at com.evermind.server.http.HttpApplication.populateLoaderWithWebService
    sDeploymentCache(HttpApplication.java:5465)
    at com.evermind.server.http.HttpApplication.populateLoader(HttpApplicati
    on.java:5394)
    at com.evermind.server.http.HttpApplication.initClassLoader(HttpApplicat
    ion.java:5333)
    at com.evermind.server.http.HttpApplication.<init>(HttpApplication.java:
    645)
    at com.evermind.server.ApplicationStateRunning.getHttpApplication(Applic
    ationStateRunning.java:428)
    at com.evermind.server.Application.getHttpApplication(Application.java:5
    12)
    at com.evermind.server.http.HttpSite$HttpApplicationRunTimeReference.cre
    ateHttpApplicationFromReference(HttpSite.java:1975)
    at com.evermind.server.http.HttpSite$HttpApplicationRunTimeReference.<in
    it>(HttpSite.java:1894)
    at com.evermind.server.http.HttpSite.addHttpApplication(HttpSite.java:15
    91)
    at oracle.oc4j.admin.internal.WebApplicationBinder.bindWebApp(WebApplica
    tionBinder.java:206)
    at oracle.oc4j.admin.internal.WebApplicationBinder.bindWebApp(WebApplica
    tionBinder.java:96)
    at oracle.oc4j.admin.internal.ApplicationDeployer.bindWebApp(Application
    Deployer.java:541)
    at oracle.oc4j.admin.internal.ApplicationDeployer.doDeploy(ApplicationDe
    ployer.java:197)
    at oracle.oc4j.admin.internal.DeployerBase.execute(DeployerBase.java:93)
    ... 4 more
    2006-11-16 20:01:15.764 WARNING java.lang.ClassCastException: com.sun.org.apache
    .xerces.internal.dom.DeferredElementNSImpl
    BTW, the service interface is added below:
    package botupws;
    public class SayHello {
    public SayHello() {
    public String say(String name) {
    return ("Hello" + name);
    The WSDL file is added below:
    <definitions
    name="MyWebService1"
    targetNamespace="http://botupws/"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:tns="http://botupws/"
    xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/"
    xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
    xmlns:tns0="http://botupws/types/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    >
    <types>
    <schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://botupws/types/"
    elementFormDefault="qualified" xmlns:tns="http://botupws/types/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:soap11-enc="http://schemas.xmlsoap.org/soap/encoding/">
    <element name="sayElement">
    <complexType>
    <sequence>
    <element name="name" type="string" nillable="true"/>
    </sequence>
    </complexType>
    </element>
    <element name="sayResponseElement">
    <complexType>
    <sequence>
    <element name="result" type="string" nillable="true"/>
    </sequence>
    </complexType>
    </element>
    </schema>
    </types>
    <message name="MyWebService1_say">
    <part name="parameters" element="tns0:sayElement"/>
    </message>
    <message name="MyWebService1_sayResponse">
    <part name="parameters" element="tns0:sayResponseElement"/>
    </message>
    <portType name="MyWebService1">
    <operation name="say">
    <input message="tns:MyWebService1_say"/>
    <output message="tns:MyWebService1_sayResponse"/>
    </operation>
    </portType>
    <binding name="MyWebService1SoapHttp" type="tns:MyWebService1">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="say">
    <soap:operation soapAction="http://botupws//say"/>
    <input>
    <soap:body use="literal"/>
    </input>
    <output>
    <soap:body use="literal"/>
    </output>
    </operation>
    </binding>
    <service name="MyWebService1">
    <port name="MyWebService1SoapHttpPort" binding="tns:MyWebService1SoapHttp">
    <soap:address location="http://192.168.5.100:8888/tanfsandbox-BotUpWS-context-root/MyWebService1SoapHttpPort"/>
    </port>
    </service>
    </definitions>
    Thanks in advance!

    This doesn't help with your specific issue, but it's an example of a WS being generated in JDeveloper then deployed to a separate standalone OC4J 10.1.3.1.0 instance.
    The WS was created from a simple Java class like yours, then deployed using JDeveloper remote connection to a separate OC4J instance.
    ---- Deployment started. ---- 17/11/2006 12:31:49
    Target platform is Standalone OC4J 10g 10.1.3 (local).
    Wrote WAR file to C:\java\jdev-10131-prod\jdev\mywork\webservices\simplest\deploy\WebServices.war
    Wrote EAR file to C:\java\jdev-10131-prod\jdev\mywork\webservices\simplest\deploy\webservices-simplest-WS.ear
    Uploading file webservices-simplest-WS.ear ...
    Application Deployer for webservices-simplest-WS STARTS.
    Copy the archive to C:\java\oc4j-10131-dev\j2ee\home\applications\webservices-simplest-WS.ear
    Initialize C:\java\oc4j-10131-dev\j2ee\home\applications\webservices-simplest-WS.ear begins...
    Unpacking webservices-simplest-WS.ear
    Done unpacking webservices-simplest-WS.ear
    Unpacking WebServices.war
    Done unpacking WebServices.war
    Initialize C:\java\oc4j-10131-dev\j2ee\home\applications\webservices-simplest-WS.ear ends...
    Starting application : webservices-simplest-WS
    Initializing ClassLoader(s)
    Initializing EJB container
    Loading connector(s)
    Starting up resource adapters
    Initializing EJB sessions
    Committing ClassLoader(s)
    Initialize WebServices begins...
    Initialize WebServices ends...
    Started application : webservices-simplest-WS
    Binding web application(s) to site default-web-site begins...
    Binding WebServices web-module for application webservices-simplest-WS to site default-web-site under context root webservices-simplest-context-root
    Initializing Servlet: oracle.j2ee.ws.server.JAXRPCServlet for web application WebServices
    Binding web application(s) to site default-web-site ends...
    Application Deployer for webservices-simplest-WS COMPLETES. Operation time: 3905 msecs
    Elapsed time for deployment: 7 seconds
    ---- Deployment finished. ---- 17/11/2006 12:31:56
    Here's the WSDL
    <definitions name="HelloWorldService" targetNamespace="http://sab.demo.webservices/">
         <types>
         <schema targetNamespace="http://sab.demo.webservices/types/" elementFormDefault="qualified">
         <element name="sayHelloElement">
         <complexType>
    <sequence/>
    </complexType>
    </element>
         <element name="sayHelloResponseElement">
         <complexType>
         <sequence>
    <element name="result" type="string" nillable="true"/>
    </sequence>
    </complexType>
    </element>
    </schema>
    </types>
         <message name="HelloWorldService_sayHello">
    <part name="parameters" element="tns0:sayHelloElement"/>
    </message>
         <message name="HelloWorldService_sayHelloResponse">
    <part name="parameters" element="tns0:sayHelloResponseElement"/>
    </message>
         <portType name="HelloWorldService">
         <operation name="sayHello">
    <input message="tns:HelloWorldService_sayHello"/>
    <output message="tns:HelloWorldService_sayHelloResponse"/>
    </operation>
    </portType>
         <binding name="HelloWorldServiceSoapHttp" type="tns:HelloWorldService">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
         <operation name="sayHello">
    <soap:operation soapAction="http://sab.demo.webservices//sayHello"/>
         <input>
    <soap:body use="literal"/>
    </input>
         <output>
    <soap:body use="literal"/>
    </output>
    </operation>
    </binding>
         <service name="HelloWorldService">
         <port name="HelloWorldServiceSoapHttpPort" binding="tns:HelloWorldServiceSoapHttp">
    <soap:address location="http://localhost:8888/webservices-simplest-context-root/HelloWorldServiceSoapHttpPort"/>
    </port>
    </service>
    </definitions>
    So it does work. What the specific problem is with your situation, one of our WS PMs most likely be able to help with.
    The error you have:
    2006-11-16 20:01:15.764 WARNING java.lang.ClassCastException: com.sun.org.apache.xerces.internal.dom.DeferredElementNSImpl
    Is strange -- can you check your WAR file and see if there are other libraries in the WEB-INF/lib that may be being loaded?
    Do you have xerces-impl.jar or anything like that in the JRE/lib directory of your JDK?
    cheers
    -steve-

  • Standalone oc4j 1.0.2.2.2

    Hi All,
    Can anyone redirect me to the url to download standalone oc4j 1.0.2.2.2 because at below this url http://otn.oracle.com/software/products/ias/htdocs/winsoftold.html
    I could see only Version 1.0.2.2.1 and Version 1.0.2.2 for download.
    Thanks & Regards,
    Kumar.

    Thank your prasad.
    I am basically using a java connection pool which stores in it cache 2-3 connections(say) to the database. However when I get this error(I dont know how it is getting ?) may be all of my connections in the cache are corrupted in one way or other then at this point if I try to invoke my web application with one of these corrupted connections in the cache then I cannot 'login into'/access my web application and so I need to restart my oc4j server so that the my java program that is deployed in the server can can new/fresh database connections and put them in connection pooling cache. So that is the reason I need to restart my oc4j server. So is there anything that I can do on my part to overcome such errors or it can be simply fixed by the help of DBA by working on the database.
    I am using my own connection pool but not the one provided by oc4j. If you get below errors:
    1. connection reset by peer
    2. broken pipe
    Then how oc4j's connection pooling will work. Can we work with our web application without restarting(to get fresh connections by destroying corrupted connections) the oc4j server.
    Thanks & Regards,
    Kumar.

  • Consuming a Web Service via SSL with Basic Authentication

    Hello,
    I have a simple web service (returns a parameter value) and want to consume it. Therefore I have generated a proxy for its in Netweaver Studio SP13.
    When I set up the web service to be accessed via HTTP and Basic Authentication (Username/Password), everything is fine. When I set up the web service to communicate via HTTPS, I get the following error message in my client:
    java.rmi.RemoteException: Service call exception; nested exception is:
         java.lang.NullPointerException
         at priv.senw04.wsproxy.multisec_ssl.SSLBindingStub.pingText(SSLBindingStub.java:87)
         at priv.senw04.wsproxy.multisec_ssl.SSLBindingStub.pingText(SSLBindingStub.java:96)
         at priv.se.wsclient.MultiSecSSL.main(MultiSecSSL.java:38)
    Caused by: java.lang.NullPointerException
         at com.sap.engine.services.webservices.jaxm.soap.HTTPSocket.disconnect(HTTPSocket.java:625)
         at com.sap.engine.services.webservices.jaxrpc.wsdl2java.soapbinding.HTTPTransport.closeSession(HTTPTransport.java:396)
         at com.sap.engine.services.webservices.jaxrpc.wsdl2java.soapbinding.MimeHttpBinding.call(MimeHttpBinding.java:1312)
         at priv.senw04.wsproxy.multisec_ssl.SSLBindingStub.pingText(SSLBindingStub.java:80)
         ... 2 more
    Testing the web service with WebServiceNavigator and/or by using a generated WebDynpro Client results in the following error:
    000D604C66BE004E0000001300000AFC00040922E0160632 : An error occurred during processing the timestamp. The error was: com.sap.security.core.ws.wss.NoSecurityHeaderException No wsse:Security header has been defined for role soap:finalActor. Please verify the policy configuration..
    But my main focus is on the client implementation based on a proxy. Here comes the client's code:
    public class MultiSecSSL {
        public static void main(String[] args) {
            try {
                MultiSecuritySSLAuthImpl serviceInterface = new MultiSecuritySSLAuthImpl();
                SSLBindingStub service = (SSLBindingStub)serviceInterface.getLogicalPort(MultiSecuritySSLAuthViDocument.class);
                SecurityProtocol protocol = (SecurityProtocol) service._getGlobalProtocols().getProtocol("SecurityProtocol");
                AuthenticationContext auth = protocol.getAuthenticationContext();
                auth.setIgnoreSSLServerCertificate(true);
                auth.setUsername("cfpcompany");
                auth.setPassword("demo");
                String ret = service.pingText("Called service MultiSecurity via SSL");
                System.out.println(ret);
            } catch (Exception e) {
                 e.printStackTrace(System.out);
    Here comes the logical port information of the generated proxy:
    <?xml version="1.0" encoding="UTF-8"?>
    <LogicalPorts Name='MultiSecuritySSLAuth' InterfaceName='priv.senw04.wsproxy.multisec_ssl.MultiSecuritySSLAuth'>
      <LogicalPort Name='SSLPort_Document' Endpoint='https://192.168.129.76:50001/MultiSecuritySSLAuth/SSL?style=document' BindingName='SSLBinding' BindingUri='urn:MultiSecuritySSLAuthWsd/SSL/document' BindingImplementation='SOAP 1.1 HTTP Binding with Attachments' StubName='priv.senw04.wsproxy.multisec_ssl.SSLBindingStub' Default='true' InterfaceName='priv.senw04.wsproxy.multisec_ssl.MultiSecuritySSLAuthViDocument' Original='true' Valid='true'>
        <globalFeatures>
          <Feature Name='http://www.sap.com/webas/630/soap/features/headers/' Provider='SoapHeadersProtocol' Original='false'>
          </Feature>
          <Feature Name='http://www.sap.com/webas/630/soap/features/session/' Provider='SessionProtocol' Original='false'>
            <Property Name='SessionMethod' Value='httpCookies'>
            </Property>
          </Feature>
          <Feature Name='http://www.sap.com/webas/630/soap/features/authentication' Provider='SecurityProtocol' Original='true'>
            <Property Name='AuthenticationLevel' Value='None'>
            </Property>
            <Property Name='AuthenticationMechanism' Value='HTTP'>
            </Property>
            <Property Name='AuthenticationMethod' Value='BasicAuth'>
            </Property>
            <Property Name='SupportsSSO2Authentication' Value='false'>
            </Property>
          </Feature>
          <Feature Name='http://www.sap.com/webas/630/soap/features/transportguarantee' Original='true'>
            <Property Name='Level' Value='No'>
            </Property>
            <Property Name='TLSType' Value='SSL'>
            </Property>
          </Feature>
        </globalFeatures>
        <localFeatures>
          <Operation Name='pingText'>
            <Feature Name='http://www.sap.com/webas/630/soap/features/wss' Original='true'>
              <Property Name='RequestPolicy' Value='Signature'>
              </Property>
              <Property Name='ResponsePolicy' Value='None'>
              </Property>
            </Feature>
            <Feature Name='http://sap.com/webservices/authorization' Original='true'>
            </Feature>
          </Operation>
        </localFeatures>
      </LogicalPort>
    </LogicalPorts>
    To me, this looks consistent. Any idea, what is misconfigured on my machine ?

    Hi Martin,
    that is exactly, what I did.
    - Change Web Service Configuration in IDE
    - Build and Deploy the Service to my local Server
    - Check Service in Visual Administrator
    - Deleted and Regenerated the Standalone Proxy
    - Deleted and Recreated the link between CLient and Proxy Project in IDE
    - Started Client
    Here comes the section of the ws-deployment-descriptor.xml of the service. For me, it matches, what the proxy generated.
      <webservice>
        <guid>ed8363_10876a54b6d__7fe9_192_168_129_76_1135862193037</guid>
        <ejb-name-temp>MultiSecWSBean</ejb-name-temp>
        <webservice-name>
          <namespaceURI>urn:MultiSecuritySSLAuthWsd</namespaceURI>
          <localName>MultiSecuritySSLAuth</localName>
        </webservice-name>
        <webservice-internal-name>MultiSecuritySSLAuth</webservice-internal-name>
        <standard-namespaceURI>urn:MultiSecuritySSLAuthWsd</standard-namespaceURI>
        <ws-configuration>
          <configuration-name>SSL</configuration-name>
          <ejb-name>MultiSecWSBean</ejb-name>
          <service-endpoint-name>
            <namespaceURI>urn:MultiSecuritySSLAuthWsd</namespaceURI>
            <localName>SSLPort</localName>
          </service-endpoint-name>
          <wsdl-porttype-name>
            <namespaceURI>urn:MultiSecuritySSLAuthWsd</namespaceURI>
            <localName>MultiSecuritySSLAuthVi</localName>
          </wsdl-porttype-name>
          <webservice-definition-ref>
            <package>com.technidata.cfp.i3rdparty.cfpxml</package>
            <name>MultiSecuritySSLAuthWsd.wsdef</name>
          </webservice-definition-ref>
          <service-endpoint-vi-ref>
            <package>com.technidata.cfp.i3rdparty.cfpxml</package>
            <name>MultiSecuritySSLAuthVi.videf</name>
          </service-endpoint-vi-ref>
          <transport-binding name="SOAPHTTP_TransportBinding">
            <wsdl-binding-name>
              <namespaceURI>urn:MultiSecuritySSLAuthWsd</namespaceURI>
              <localName>SSLBinding</localName>
            </wsdl-binding-name>
          </transport-binding>
          <transport-address>/MultiSecuritySSLAuth/SSL</transport-address>
          <global-features>
            <feature name="http://www.sap.com/webas/630/soap/features/transportguarantee" protocol="SecurityProtocol">
              <property name="TLSType" value="SSL"/>
            </feature>
            <feature name="http://www.sap.com/webas/630/soap/features/authorization" protocol="SecurityProtocol"/>
            <feature name="http://www.sap.com/webas/630/soap/features/authentication" protocol="SecurityProtocol">
              <property name="AuthenticationMethod" value="BasicAuth"/>
              <property name="AuthenticationMechanism" value="HTTP"/>
              <property name="SupportsSSO2Authentication" value="false"/>
            </feature>
          </global-features>
          <operation-configuration uniqueViName="pingText(java.lang.String)">
            <transport-binding-configuration>
              <input>
                <property name="soapAction" value=""/>
                <property name="encodingStyle" value="http://schemas.xmlsoap.org/soap/encoding/"/>
              </input>
              <output>
                <property name="encodingStyle" value="http://schemas.xmlsoap.org/soap/encoding/"/>
              </output>
            </transport-binding-configuration>
            <feature name="http://www.sap.com/webas/630/soap/features/wss" protocol="SecurityProtocol">
              <property name="RequestPolicy" value="None"/>
              <property name="ResponsePolicy" value="None"/>
            </feature>
            <feature name="http://sap.com/webservices/authorization" protocol="SecurityProtocol">
              <property name="security-roles">
                <property name="role1" value="use_multisec_service"/>
              </property>
            </feature>
          </operation-configuration>
        </ws-configuration>
      </webservice>
    Regards,
    Stefan

  • Problem consuming web service with basic authentication

    Hello,
    I've set up a web service with basic authentication. Although I have to log in before being able to open the overview page of the web service in the Web Service Navigator, the response I get after sending a request is:
    Authority check failed
    I get this response in the Web Service Navigator as well as when consuming the web service via standalone proxy classes.
    The following is strange, too: It is not possible to change  authentication in the generated logical port. It is set to "none". I changed it via the XML file where I added the properties "AuthenticationMethod" (value "BasicAuth") and "AuthenticationMechanism" (value "HTTP"). But I got the above response anyway.
    Thanks for your help!
    Regards

    I used basic authentication for my web service.
    I was able to obtain a hardcopy of the logfiles in the meantime. The invocation of the web service is stored there with the following error messages:
    <i>SOAP Runtime: Exception message: Schwerer Prozessierungsfehler macht eine SOAP-Fault-Behandlung erforderlich
    SOAP Runtime: SOAP Fault exception occurred in program CL_SOAP_RUNTIME_SERVER========CP in include CL_SOAP_RU NTIME_SERVER... [the picture is cut here]</i>
    In addition to that I found a thread in SDN that dealt with exactly the same problem:
    Web Service Homepage: Authority check failed
    But I have the same problem like Kimberly Carmack (the last post on the second page). We do not have that role in our system.

  • Cost of standalone OC4J

    Hi,
    I would like to set up Apache FOP for basic pdf generation in Apex reports. Does anyone know how much it cost for standalone OC4J - per CPU? Also, has anyone tried to use OC4J/FOP for basic PDF in Apex reports? Is the result stable? Finally, is there any software that allows XSL:FO formatting of the report template?
    Thanks.
    Andy

    Hi,
    I do not know license cost for OC4j
    You could think use Tomcat and Cocoon
    http://ubuntuforums.org/showthread.php?t=1004742
    http://carlback.blogspot.com/2007/03/apex-cocoon-pdf-and-more.html
    Or check this
    Jasper Reports Integration - beta release
    Regards,
    Jari

  • Error in basic authentication after SPNego implementation

    Hi all!
    I have implemented integrated Windows authentication (SPNego-Kerberos) and after change login modules some external applications developed in .NET using Basic authentication couldn't logon. I know this error can be fixed modifing .NET code but in this company we don't have an knowleadge of all the applications consuming PI Web Servicies in production environment.
    Do you have an idea to solve this?
    Thanks in advance.

    Hi All,
    thanks for your help. We have rised OSS note to SAP and they have identifyed that the problem is in MDM Java API and Portal Contents. They provided fix (Patch 14) and now it is OK - see SAP note: Note 1464966 - MDM 7.1 SP04 Patch12 Release Note
    MDM Java API:
    Fixed: During the creation of the MDM session with MDM repository from MDM portal standard iViews or custom application (standalone or in portal), the following error message appears in the portal default trace: "Can not authenticate repository session# because user password is not specified" or "Can not trust user session.."  and in addition, the corresponding trace logs contains the following entry "BlobCacheImpl.retrieveSchema" (O 320008 2010 and O 327326 2010).
    MDM Portal Content (iViews):
    Fixed: During the creation of the MDM session with MDM repository from MDM portal standard iViews, the following error message appears in the portal default trace: " Can not authenticate repository session# because user password is not specified "  or "Can not trust user session.."  and in addition, the corresponding trace logs contains the following entry "BlobCacheImpl.retrieveSchema". If the corresponding MDM Java API fix has been applied, applying the MDM iViews fix is not required, since the Java API issue should be sufficient (O 320008 2010 and O 327326 2010).
    Thanks&Regards,
    ILIN

  • Transport level - Basic Authentication

    Hi,
    How do we set transport level basic authentication credentials (username, password) after creating a webservice proxy project. I tried the requestContext, and I think it should be somewhere else, as the service provider is using transport level basic authentication.
    Any help or direction is appreciated.
    Thank you,
    VJ

    This worked for me. If this helps anyone-
    I closed the existing application. Created a new application, and then created the web service proxy. After which, in the ServiceSoap12BindingQSPortClient commented out the
    existing setPortCredentialProviderList(requestContext), and have added the following:
    reqContext.put(BindingProvider.USERNAME_PROPERTY,"user");
    reqContext.put(BindingProvider.PASSWORD_PROPERTY,"password");
    reqContext would be - Map<String, Object> reqContext = ((BindingProvider) sersServiceV3PortType).getRequestContext();, which is generated already.
    I would be using this standalone project as a component.
    Thanks,
    VJ
    Edited by: VJ on Jul 27, 2011 9:08 AM

  • Standalone OC4J 10.1.3 + OID(IM 10.1.2.0.2 with SSO) issue

    Hi!
    We have successfully made Identity Manager 10.1.2.0.2 (SSO) to work with the full OAS 10.1.3, by generating osso.conf file, as explained on chapter 6 of OC4J security guide. However, we have no clue on how to do it for Standalone OC4J. Such versoin has no Apache directory in order to run osso1013 script on.
    Any help would be much appreciated.
    Thanks in advance.
    Best Regards,
    Gustavo

    The SSO Registration tool is meant for OracleAS, not standalone OC4J. Since you are not using OHS, I don't know how you will be redirected to the login page.
    As far as OC4J goes, the configuration would be as follows.
    For use of Oracle Single Sign-On for authentication, the auth-method attribute is set to "SSO" in the <jazn-web-app> element (a subelement of the <jazn> element) in the OC4J orion-application.xml file.
    Here is a sample entry:
    <orion-application ... >
    <jazn provider="LDAP" >
    <jazn-web-app auth-method="SSO"/>
    </jazn>
    </orion-application>
    You would also have to associate OC4J with the Identity Management Infrastructure
    Message was edited by:
    wbathurs

  • How to access SOAP web service with authentication, HTTP basic Authentication

    Dear All
    i use Flash Builder 4.5, flex 4..1, i am developing a flex client to soap webservices hosted over Glassfish 2 Java server, the web services is protected by HTTP Basic Authentication, everythime i run my code , the prombt for username and password show up, i need to pass user name and password through action script, i followed the flollowing (but was for http web service, not soap) but really did not work.
    http://stackoverflow.com/questions/490806/http-basic-authentication-wi th-httpservice-objects-in-adobe-flex-air
    http://forums.adobe.com/message/4262868
    private function authAndSend(service:HTTPService):void
            var encoder:Base64Encoder = new Base64Encoder();
            encoder.insertNewLines = false; // see below for why you need to do this
            encoder.encode("someusername:somepassword");
            service.headers = {Authorization:"Basic " +encoder.toString()};                                               
            service.send();
    Also i noticed in debug mode, always that WARNNING raised up
    Warning: Ignoring 'secure' attribute in policy file from http://fpdownload.adobe.com/pub/swz/crossdomain.xml.  The 'secure' attribute is only permitted in HTTPS and socket policy files.  See http://www.adobe.com/go/strict_policy_files for details.
    any idea ?

    Hello,
    I don't know if this could help.
    Another way to connect to a web service by SOAP and WSDL is to click on the Data/Services panel, then click on "Connect to Data/Services" and then select the "Web Service" (WSDL) icon. This could help as well.

  • Help needed for using BASIC authentication through JDBCRealm

    Help needed.
    Hello,
    I am doing a degree project, so far it works fine in my local machine, I need to try it on my virtual hosting (as it is a live server).
    My project requires JDBCRealm, that is BASIC authentication loading access data from mysql database. Normally this setup can be done in Server.xml file, because my Tomcat hosting is a virtual one, I only have permission to access the web.xml file.
    My question is: is it possible to get it done in an alternative way? In web.xml? Some properties file maybe?
    Thank you very much.

    You can set this up for your context using META-INF/context.xml instead of working with server.xml.
    Make a directory called META-INF under your webapp ( it'll be at the same level as WEB-INF ). Under this, add a context.xml with all your context specific configuration including the realm. A sample is below
    <?xml version="1.0" encoding="UTF-8"?>
    <Context path="/myApp" reloadable="true">
        <Realm
            className="org.apache.catalina.realm.JDBCRealm"            
            driverName="com.microsoft.jdbc.sqlserver.SQLServerDriver"         
            connectionURL="jdbc:microsoft:sqlserver://127.0.0.1:1433;DatabaseName=myDB;SelectMethod=Cursor;"
            connectionName="username" connectionPassword="password"
            digest="MD5" userTable="users" userNameCol="userid" userCredCol="userpassword"
            userRoleTable="user_roles" roleNameCol="rolename"
        />
    </Context>Hope this helps.
    People on the forum help others voluntarily, it's not their job.
    Help them help you.
    Learn how to ask questions first: http://faq.javaranch.com/java/HowToAskQuestionsOnJavaRanch
    ----------------------------------------------------------------

  • Forms based authentication + Basic authentication = no way to use the basic auth!!!!

    Hi,
    I setup a test sharepoint site, claims mode, with both the forms and basic authentication  enabled.
    I expect to see the page asking me which authentication method I want to use, but I never see this page!!!
    I have to select the windows authentication (NTLM or Kerberos) to see this page!
    why using only the Basic authentication did not prompt the user?
    and how to be authenticated using the basic authentication rather than the forms auth when both are enable for the same site?
    >I do NOT want to extend my site to have 2 zones... my question is ONLY with 1 zone configured.

    What is the business purpose for using Basic Auth over NTLM/Kerberos?
    Trevor Seward
    Follow or contact me at...
    &nbsp&nbsp
    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

  • Deploy ADF application to standalone OC4J 11g

    Hi people!
    I found some threads into the forums that deal with the subject but I did not find any solution, so I post a new thread...
    In fact, I'd like to deploy a "war" on a standalone oc4j 11g.
    The application was built with jdev 11g TP4.
    I can't use the ADF runtime Installer of jdev, so I have to copy all the files by myself, but the problem is that I do not find the files in jdev11/BC4J/lib/ that I have to copy in oc4j/BC4J/lib...
    There is no adfcm.jar, bc4jdomorcl.jar, etc ...
    Is it normal ? Could someone indicate me how to configure the standalone oc4j 11g in order to deploy my "war" ?
    Thanks a lot,
    romain.
    Edited by: Romain Testu on 24 sept. 2008 09:28

    Hi,
    TP4 doesn't have a standalone OC4J.
    Try to start embedded oc4j from jdeveloper in standalone mode.
    see e.g. Re: Can Jdeveloper TP4 deploy apps to OC4J standalone TP4
    BTW: The production release 11g is announced within next week and this release will contain Weblogic Server 10gR3 instead of OC4J.
    JDeveloper 11g release this month?
    regards
    Peter

Maybe you are looking for

  • My apple ID

    Hi, I'm recently changed my apple ID from Saudi Arabia to US account and I already have many apps purchased on Saudi Account. the problem that now I can not updates these apps in iTunes after I changed the account, it said "no updates currently avail

  • How can I get a better looking NTSC video showing on an Apple TV?

    Filming on Mini DV tapes using a JVC GY-DV500 camcorder. Capturing via Firewire 400. What I've been doing is capturing and editing with the DV NTSC 48 khz presets. I export "using QuickTime conversion" for Apple TV. The problem I have is that the vid

  • HP Officejet Pro 8500 won't install

    My HP Officejet Pro 8500 won't install on my second Macbook Air (while it did on my first; both new Macbooks with up to date software). The message I get is: "Softwareaktualisierung kann aufgrund eines Netzwerkproblems nicht nach Updates suchen." (Up

  • Publish: Scalable, HTML5, SWF Not working on Android 4.1.1

    In Captivate 6, I publish with SWF, HTML5, and Scalable HTML content. It will not run on the Samsung Galaxy S3 (Android 4.1.1). What do I need to change.

  • Parallel Port

    I have an application that uses the parallel port. It works fine on Win2K using the AccessHW stuff. However, the piece of hardware I have hanging off the parallel port requires the parallel port to be put in SPP or AT mode. I change the mode in the c