Simulate multiple request / response with a HTTP URL

I need to communicate with a servlet. In the first request, the user gets authenticated and a connection is created. Now I need to use this connection to send further requests since all requests undergo an authentication check.
However, when I try to implement the same, the second time I write to the output stream of the connection, I get the following exception:
java.net.ProtocolException: Cannot write output after reading input.
Please help! I need to create an application which communicates with this Servlet in the specified way

Now I need to use this connection to send
further requests since all requests undergo an
authentication check.That's not how HTTP works. For each request, you have
to make a new connection. And as for authentication,
it's perfectly feasible for you to do the
authentication for every single request, but (at
least in the case of basic authentication) browsers
tend to send an Authorization header once they have
done the original authentication dialogue. You could
do that too.Also, underneath it all, HTTP 1.1 tries to maintain a socket connection so you don't have that overhead to deal with each time. But as DrClap says, you need to use fresh HTTP instances each time and set the appropriate session/authentication headers.

Similar Messages

  • Need help with contacting HTTPS URL

    Hi,
    I am new bie to Java Security. I do not know where to start off with. Here is the requirement.
    I need to contact an HTTPS URL and this URL gives me output which is encypted data.
    I have to save this ecnrypted data into a file and I have the KEY to decrypt the data.
    I have tried several ways (all listed below) to get it working. But I am not successful. I get
    "javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: No trusted certificate found"
    Can you guys give me some insight on how to proceed?
    Thanks
    Mathew
    import java.util.*;
    import java.text.*;
    import java.net.*;
    import java.io.BufferedReader;
    import java.io.InputStreamReader;
    import java.net.HttpURLConnection;
    import java.net.URL;
    import java.security.Permission;
    import javax.net.ssl.HttpsURLConnection;
    import java.security.*;
    import java.security.cert.*;
    import javax.net.ssl.*;
    import java.io.*;
    public class temp
         protected BufferedReader messageResponseReader;
         private static final String CERTIFICATE_TYPE = "SunX509";
         private static final String KEYSTORE_TYPE = "JKS";
         private static final String SSL_PROTOCOL = "TLS";
         private static final String CERTIFICATE_FACTORY_TYPE = "X.509";
         public static void main(String args[])
              try
                   try{
                             temp tmp = new temp();
                             String url = "https://test.mysite.com/one/perform.jsp?mode=get&check=true";
                             tmp.sendRequest(url);
                        }catch(Exception e)
                             e.printStackTrace();
              catch(Exception e){
                   e.printStackTrace();
    public String sendRequest(String urlString) throws Exception
    StringBuffer response = null;
    BufferedReader messageReader = null;
    try
                   String username = "user";
                   String password = "pwd";
                   String encoding = new sun.misc.BASE64Encoder().encode("username:password".getBytes());
                   //java.security.Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider());
                   //System.setProperty("java.protocol.handler.pkgs", "com.sun.net.ssl.internal.www.protocol");
                   // Needed for validation of the server certificate
                   //System.setProperty("javax.net.ssl.trustStore","C:\\cert\\key.txt");
                   // Needed for providing a clint certificate for client authentication
                   //System.setProperty("javax.net.ssl.keyStore","C:\\cert\\key.txt");
                   //System.setProperty("javax.net.ssl.keyStorePassword","te5t1ng");
                   //System.setProperty("ssl.SocketFactory.provider", "com.sun.net.ssl.internal.ssl.Provider");
                   KeyStore ks;
                   ks = KeyStore.getInstance("JKS");
                   CertificateFactory cf = CertificateFactory.getInstance(CERTIFICATE_FACTORY_TYPE);
                   TrustManagerFactory tmf = TrustManagerFactory.getInstance(CERTIFICATE_TYPE);
                   KeyManagerFactory kmf = KeyManagerFactory.getInstance(CERTIFICATE_TYPE);
                   FileInputStream fis = new FileInputStream("C:\\cert\\key.txt");
                   BufferedInputStream bis = new BufferedInputStream(fis);
                   Collection c = cf.generateCertificates(fis);
                   Iterator i = c.iterator();
                   while (i.hasNext()) {
                   java.security.cert.Certificate cert = (java.security.cert.Certificate)i.next();
                   System.out.println(cert);
                   ks.load(null, null);
                   X509Certificate the_cert = (X509Certificate)cf.generateCertificate(bis);
                   ks.setCertificateEntry("server_cert",the_cert);
                   tmf.init(ks);
                   ks = KeyStore.getInstance(KEYSTORE_TYPE);
                   ks.load(null, null);
                   the_cert = (X509Certificate)cf.generateCertificate(new FileInputStream("key.txt"));
                   ks.setCertificateEntry("client_cert",the_cert);
                   kmf.init(ks, null);
                   SSLContext ctx = SSLContext.getInstance(SSL_PROTOCOL);
                   KeyManager[] km = kmf.getKeyManagers();
                   TrustManager[] tm = tmf.getTrustManagers();
                   ctx.init (km, tm, null);
                   HttpsURLConnection.setDefaultSSLSocketFactory(ctx.getSocketFactory());
    urlString = urlString.replaceAll(" ","%20");
    URL url = new URL(urlString);
    //HttpsURLConnection urlCon = (HttpsURLConnection)url.openConnection();
    HttpURLConnection urlCon = (HttpURLConnection)url.openConnection();
    //com.sun.net.ssl.HttpsURLConnection urlCon = (com.sun.net.ssl.HttpsURLConnection)urlCon;
    /*urlCon.setRequestProperty("Host", url.getHost());*/
    urlCon.setDoOutput(true);
    urlCon.setDoInput(true);
    urlCon.setRequestMethod("POST");
    urlCon.setUseCaches (false);
    urlCon.setAllowUserInteraction(true);
    urlCon.setInstanceFollowRedirects(true);
    urlCon.setRequestProperty ("Authorization", "Basic " + encoding);
    //Permission permision = urlCon.getPermission();
    //System.out.println("permission name:"+permision.getName());
    urlCon.connect();
    //messageReader = new BufferedReader(new InputStreamReader(urlCon.getInputStream()));
    //response = new StringBuffer();
    //String line;
    //while((line = messageReader.readLine()) != null){
    // response.append(line);
    // response.append("\n");
    catch (Exception e) {
    e.printStackTrace();
    throw e;
    return "testing";

    sorry for the junk data.. Need to post it again

  • Start a scenario with a http url

    I try to launch a scenario by using an http url witthout success. ( NullPointer exception)
    I use Tomcat 4.1 and I have deployed Matadata Navigator on it
    I send the followings parameters to the URL http://localhost:8080/oracledimn/startscen.do
    name="agent_name" value="192.168.2.12"
    name="agent_port" value="20910"
    name="master_driver" value="oracle.jdbc.driver.OracleDriver"
    name="master_url" value="jdbc:oracle:thin:@manet:1521:std9devb"
    name="master_user" value="odimait_devb"
    name="master_psw" value="d,yayCGpmzmfTBoS38I2zFS,r"
    name="work_repository" value="REF TRAVAIL INVS DEV BORDEAUX"
    name="snps_user" value="SUPERVISOR"
    name="snps_psw" value="fDyXGs0FL,8E6hRhgIVs"
    name="scen_name" value="INVS_PMSI"
    name="scen_version" value="1"
    name="context_code" value="INVS_PMSI"
    name="log_level" value="5"
    name="http_reply" value="HTML"
    I have no problem to run the scenario thru the Metadata Interface itself.
    any idea ?
    thanks for your response
    jbl

    I have found the solution :
    the scenario version was : 001, one have to keep de leadings 0

  • How to 'tunnel' requests/response with servlet?

    Hallo!
    I have the following problem.
    Tomcat is used as ServletEngine. Here should work a servlet for authorization. The web application resides on another webserver.
    After authorization all request go to Tomcat where a servlet should get (via HTTP) the HTML-pages from the other webserver and sends them to the client. The customer wants to act the Tomcat as Server to the client and as client to the other webserver. For me it seems to be some kind of proxy functionality.
    How can I achieve this?
    Kind regards
    Jochen

    Hi,
    I am currently writing almost the same thing. And I have a partial success with something like ProxyServlet. What it does:
    1. creates a URL object
    2. creates HttpURLConnection through the URL
    3. copies servlet's request parameters to the HttpURLConnection's request
    4. copies the HttpURLConnection's response to the servlet's response
    It works, but it is very - very slow.
    I am currently struggling with the Keep-Alive feature in HTTP 1.1 that the remote server sends. If I copy that header onto the response, the client sends another request to the same channel, that is mean while broken - the servet is used only by one to one.
    I am trying to find something like URL Connection pool, but still I am not successful. I am going to try not to trasfer the Keep-Alive headers to the client - perhaps this sort of downgrading Http 1.1 to 1.0 will limit the timeout delays ...
    Did you succeed in your work ?
    Ales

  • How to do multiple requests/responses sequentially to same COM port?

    I can read 5 different values from my instrument. Each have their own command letter for sending over the value.
    How do I read these values sequentially?

    I am attaching an example which demos this using the ASCII Object. The example, for simplicity, uses a loop-back on COM1. I suggest you do the same while studying the example: short pins 2 and 3 on your COM1.
    In the example, values from Column A and Column B of the DataTable are packed and sent out as the "command." So, you would replace this with your intrument commands. The response (which is the same as "command" in this case because of the loop-back) is read, parsed (the number from the text) and then stored in Column C of the DataTable.
    This can be easily made to run automatically using a Timer/Counter.
    Hope this helps.
    Regards,
    Khalid :
    Attachments:
    simpleserdriver.lks ‏10 KB

  • BLS in MII Version 11.5 - HTML Loader with a HTTPS URL ASP Page

    Greetings All,
    In my Business Logic, I have a need to scrape some information off of a Https Webpage but my HTML Loader is getting the following error:
    [ERROR]: HTMLLoader [https://midstream.epplp.com/standard/login.asp] : sun.security.validator.ValidatorException: No trusted certificate found
    Any idea how I can correct this issue.
    I'll eventually have to HTTP Post back to sign in and navigate the site but that also gives the same error...
    Thanks

    BLS will need the certificate to exist in the cacerts file of the jdk of the mii server.
    which for me is located in
    \Program Files\Java\jdk1.5.0_14\jre\lib\security
    You need to import the certificate using the java keytool.  See
    http://java.sun.com/j2se/1.5.0/docs/tooldocs/solaris/keytool.html
    but first you will need to get the certficate.
    Jamie

  • "https" url with URLConnection

    If I use URLConnection to connect to a servlet with a https url, and supposed I have the required CA public key loaded in my keystore, would that turn on ssl connection?
    Thanks in advance.
    =yu

    after more reading... yes, it will work (Notice that for previous version of JSK1.4.2, the protocol handler should be set correctly), the URL/URLStreamHandler class will do the runtime binding for a specific protocol.
    -yu

  • Multiple requests in a single HttpConnection

    this is the point,
    I would like to make a while that sends multiple requests, but with just one HttpConnection.
    something like this:
    import java.io.DataInputStream;
    import java.io.DataOutputStream;
    import java.io.IOException;
    import javax.microedition.io.Connector;
    import javax.microedition.io.HttpConnection;
    public class Ping extends Thread {
        String url;
        HttpConnection conn = null;
        DataInputStream hdin = null;
        DataOutputStream hdout = null;
        public Ping(String url) {
            this.url = url;
        public void openConnection() {
            try {
                conn = (HttpConnection) Connector.open(url);
                conn.setRequestMethod(HttpConnection.POST);
            }  catch(Exception e) {
                e.printStackTrace();
        public void efetuaConsulta() {
           int counter = 0;
           try {
                if(null == conn)
                    openConnection();
                while(counter <= 10) {
                    hdout = conn.openDataOutputStream();
                    hdout.writeInt(counter);
                    hdout.flush();
                    hdout.close();
                    hdin = conn.openDataInputStream();
                    counter = hdin.readInt() + 1;
                    hdin.close();
                    System.out.println("--> "+counter);
            } catch(Exception e) {
                e.printStackTrace();
        public void run() {
            efetuaConsulta();
    }well, this the idea, but its not working....
    this class would send an incremented int every request to my servlet,
    in another project, my servlet would do something....
    but this is not working because it says my DataOutputStream is already opened.
    I tried to do a singleton too, but it doesnt work....
    someone knows how to do it?
    I know it's possible because midp1.0 supports HTTP1.1
    and HTTP1.1 support what Im trying to do here....

    Http 1.1 is not supported. You could implement that yourself...
    try to move the openconnection into the while loop. that should work

  • Name of .crl and .crt file missing from HTTP URL in certificate details

    Hello Everyone,
    I am in the process of building a 2-tier Windows Server 2012 R2 PKI. The CA name of both the offline standalone root CA and enterprise subordinate CA have spaces in it (we'll call the CA name, 'Test Lab Root CA' for point of reference).
    When I submitted the certificate request for the subordinate CA to the root CA and viewed the attributes/extensions of the pending request, I noticed the HTTP URL is missing the name of the .crt and .crl file.
    The AIA extension reads URL=http://test.domainname.com/pki/.crt
    in the issued certificate details.
    The CDP extension reads URL=http://test.domainname.com/pki/.crl
    in the issued certificate details.
    The AIA and CDP location HTTP URLs are configured as http://test.domainname.com/pki/<CertificateName>.crt and  http://test.domainname.com/pki/<CRLNameSuffix><DeltaCRLAllowed>.crl, respectively on the
    root CA. 
    The LDAP URL shows the .crt and .crl file name (with %20 replacing the spaces) perfectly fine. The LDAP URL is configured using variables as well. It's just the HTTP URL that is missing the name of the file altogether. 
    I have read about the issue where spaces are not being replaced with %20 in the URL on Windows Server 2012 and a hotfix is available for that issue. But this issue seems to be slightly different and I'm running Windows Server 2012 R2. I tried installing
    the hotfix to see if it would help, but the hotfix can't install because it doesn't apply to Server 2012 R2.
    I've been trying to find a technet discussion or blog article for a week to see if anyone has seen this and what the fix is, but I'm coming up empty. I only find talks about %20 not replacing the space in the name.
    Does anyone have any insight to my particular issue? I don't want to issue the subordinate CA certificate until I know the HTTP URL populates the CRL and CRT file name correctly. I can get around this by typing out the name of the file (with spaces and not
    %20... e.g. http://test.domainname.com/pki/Test Lab Root CA.crl) in the URL via the registry and the URL displays the name of the file (with %20 in the name) when I do another certificate request and check the attributes/extensions in the
    pending request. However, I prefer to avoid manually typing out the name of the file in the registry. I'd like to use the variables if at all possible. 
    Any help/guidance would be greatly appreciated.
    Thank you.

    On Fri, 27 Mar 2015 03:42:28 +0000, Brian Komar [MVP] wrote:
    You have totally messed up the URLs.
    If you run certutil -getreg ca\CRLPublicationURLs and certutil -getreg ca\CACertPublicationURLs, you will see that you do not have correct use of variables when compared to the settings that follow:
    The URLs should be set to the following for an offline CA:
    certutil -setreg CA\CRLPublicationURLs "1:%WINDIR%\system32\CertSrv\CertEnroll\%%3%%8%%9.crl\n2:http://test.domainname.com/pki/%%3%%8%%9.crl"
    *certutil -setreg CA\CACertPublicationURLs  "1:%WINDIR%\system32\CertSrv\CertEnroll\%%1_%%3%%4.crt\n2:http://*test.domainname.com*/pki/%%1_%%3%%4.crt"*
    For an issuing CA, they should be set to:
    The URLs should be set to the following for an offline CA:*certutil -setreg CA\CRLPublicationURLs "65:%WINDIR%\system32\CertSrv\CertEnroll\%%3%%8%%9.crl\n6:http://test.domainname.com/pki/%%3%%8%%9.crl"*
    *certutil -setreg CA\CACertPublicationURLs  "1:%WINDIR%\system32\CertSrv\CertEnroll\%%1_%%3%%4.crt\n2:http://**test.domainname.com**/pki/%%1_%%3%%4.crt"*
    Just a clarification here, if you're running the above certutil commands at
    the command prompt you only need single % characters in the command line.
    The double % characters are only required if the commands are being run in
    a batch file.
    Paul Adare - FIM CM MVP

  • CS4 crash: preview an image with a secure URL

    Every time I create an image with a HTTPS URL as the image location, DW hangs/crashes.
    This is a relatively recent problem (last 4 months or so)... I do a few game related sites, and we have to include this image all the time in the footer. Unfortunantly, we cannot host this image locally:
    Including code:
    <html>
    <head>
    </head>
    <body>
    <img src="https://www.esrb.org/privacy/members/privacy_certified-2008.gif">
    </body>
    </html>
    Anyone know a workaround - or settings that might be causing this?
    TIA
    kcr
    CS4 DREAMWEAVER v10 build 4117
    Win7 64
    Message was edited by: kcroy2011

    This happens to me too, with Mountain Lion. It appears to be a bug in Preview. If the file starts out as something without transparency, a jpeg or even a png without transparency, Preview doesn't save it with transparency, even though Preview says it is - check the info for the image.
    I have just found a workaround which may be useful: Take a screenshot of your image, then use instant alpha on that. It will be saved with transparency - look under info/general  in the info panel.

  • Separating "concatenated responses" with a carriage return?

    How can you separate multiple text responses with a carriage return?
    Nothing looks good, semicolons and periods not working well.
    Any ideas?

    I'm using a Mac.
    I'd like to separate individual responses in the summary column with a carriage return, so if the first response in the table column is "Fortunate" and the next response below it is "Random", and then "Bob's your uncle", what shows up right now with =concatenate(@column & ";  ") isn't quite what I want (shows up as: Fortunate;  Random;  Bob's your uncle;  ).
    I'd like it either to show up as numbered responses (ie, 1. Fortunate  2. Random  3. Bob's your uncle)
    Or show up as:
    Fortunate
    Random
    Bob's your uncle
    Thanks for the help.

  • AutoVue applet return HTTP response code: 403 for URL with chinese characte

    Dear All,
    When i integrate with AutoVue Server 19.3 Using AutoVue applet into my web application it returns the following exception
    java.io.IOException: Server returned HTTP response code: 403 for URL: http://.....
    when the file name have chinese characte,but when the file name have no chinese characte and all the normal
    Anyone can help?
    Best Regards

    There are many possible causes of a 403 error. Is this error happening when launching the applet, or does the applet launch properly and the error comes up when loading the file? How do you have AutoVue integrated to your web application? Is it integrated using the AutoVue ISDK? Or are you passing filenames into the applet in a different way? Can you clarify again, does the error only occur when the user tries to open a Chinese filename?
    Also, please note that AutoVue version 19.3 is no longer under Oracle Premier Support. If possible you should upgrade to the latest version of AutoVue, especially if you end up needing to log a Service Request to Oracle.

  • Problems with SAP BC to post a request to https URL

    Hello,
    in a integration scenario one of our partners wants to send a xml to our server via https.<br/>
    I tried this internal with a test business connector. I simple use the WmPublic.pub.client http service.<br/>
    I try to post a record to an https:// URL and get an error. It seems that there is some trouble with the ssl handshake. However it is working in the browser.<br/>
    The option Security -> Certificates -> Trusted Certificates -> CA Certificates Directory is 'unspecified'. Therefore no server certificate should be reject.<br/>
    <br/>
    Now I got an 'iaik.security.ssl.SSLException: Peer sent alert: Alert Fatal: handshake failure<br/>
    ' error. I do not find any helpful entries in this forum. Did anyone solve this issue?<br/>
    <br/>
    Thank you,<br/>
    Nils<br/>
    <br/>
    error:<br/>
    2009-08-03 10:08:13 CEST iaik.security.ssl.SSLException: Peer sent alert: Alert Fatal: handshake failure<br/>
         at iaik.security.ssl.r.f(Unknown Source)<br/>
         at iaik.security.ssl.x.b(Unknown Source)<br/>
         at iaik.security.ssl.x.a(Unknown Source)<br/>
         at iaik.security.ssl.r.d(Unknown Source)<br/>
         at iaik.security.ssl.SSLTransport.startHandshake(Unknown Source)<br/>
         at iaik.security.ssl.SSLTransport.getInputStream(Unknown Source)<br/>
         at iaik.security.ssl.SSLSocket.getInputStream(Unknown Source)<br/>
         at com.wm.net.NetURLConnection.trySSLConnect(NetURLConnection.java:691)<br/>
         at com.wm.net.NetURLConnection.httpsConnect(NetURLConnection.java:562)<br/>
         at com.wm.net.NetURLConnection.connect(NetURLConnection.java:171)<br/>
         at com.wm.net.HttpURLConnection.getOutputStream(HttpURLConnection.java:419)<br/>
         at com.wm.net.HttpContext.getOutputStream(HttpContext.java:578)<br/>
         at com.wm.net.HttpContext.getOutputStream(HttpContext.java:554)<br/>
         at com.wm.net.HttpContext.post(HttpContext.java:338)<br/>
         at pub.client.http(client.java:512)<br/>
    <br/>
    SAP BC Info:<br/>
    Software <br/>
    Product webMethods Integration Server <br/>
    Version 4.6 (Standard Encryption)    Release Notes  <br/>
    Updates BC46_CoreFix7  <br/>
    Build Number 940 + CoreFix 7 [Fixes 1-205 + SP1-3] <br/>
    SSL Standard (40-bit), Provider: IAIK 2.6 <br/>
      <br/>
    Server Environment <br/>
    Java Version 1.3.1_20 (47.0) <br/>
    Java Vendor Sun Microsystems Inc. <br/>
    Java Home /usr/jdk1.3.1_20/jre <br/>
    Java VM Version 1.3.1_20-b03 <br/>
    Java VM Info Java HotSpot(TM) Client VM (mixed mode) <br/>
    Classpath /usr/local/sapbc46/server/updates/BC46_CoreFix7.jar<br/>
    /usr/local/sapbc46/server/lib/server.jar<br/>
    /usr/java/lib/i18n.jar<br/>
    /usr/java/jre/lib/rt.jar<br/>
    /usr/java/lib/i18n.jar<br/>
    /usr/java/jre/lib/rt.jar<br/>
    /usr/java/lib/i18n.jar<br/>
    /usr/java/jre/lib/rt.jar<br/>
    /usr/java/lib/i18n.jar<br/>
    /usr/java/jre/lib/rt.jar<br/>
    /usr/java/lib/i18n.jar<br/>
    /usr/java/jre/lib/rt.jar<br/>
    /usr/java/lib/i18n.jar<br/>
    /usr/java/jre/lib/rt.jar<br/>
    /usr/local/sapbc46/server/lib/classes<br/>
    /usr/local/sapbc46/server/lib/client.jar<br/>
    /usr/local/sapbc46/server/lib/mail.jar<br/>
    /usr/local/sapbc46/server/lib/server.jar<br/>
    packages/SAP/code/classes<br/>
    packages/SAP/code/jars/static/inqmyxml.jar<br/>
    packages/SAP/code/jars/static/jARM.jar<br/>
    packages/SAP/code/jars/static/jCO.jar<br/>
    packages/SAP/code/jars/static/sapjco.jar<br/>
    packages/SAP/code/jars/static/sapxmltoolkit.jar<br/>
    packages/WmPartners/code/classes<br/>
    packages/WmWin32/code/classes <br/>
    OS Linux <br/>
    OS Platform i386 <br/>
    OS Version 2.6.18.8-0.13-default <br/>
    Current User sapbc <br/>
    Working Dir /usr/local/sapbc46/server<br/>

    Ok - in this case you need to include to session based SSL setup in your flow (scenario).
    The pub.security:setKeyAndChain and pub.security:clearKeyAndChain services are used to control which client certificate
    the SAP BC server presents to remote servers. You need to use these services to switch between certificates and
    certificate chains if you are not using aliases for remote servers.
    List of services to be used:
    pub.security:clearKeyAndChain
    -- Associates the default key and certificate chain with the subsequent set of invoked services.
    pub.security:setKeyAndChain
    -- Processes a digital signature to make sure that the provided data has not been modified. The signature input is the DER encoding of the PKCS#7 SignedData object.
    pub.security.pkcs7:sign
    -- Creates a PKCS7 SignedData object.
    pub.security.pkcs7:verify
    -- Processes a digital signature to make sure that the provided data has not been modified.
    pub.security.util:createMessageDigest
    -- Generates a message digest for a given message.
    pub.security.util:getCertificateInfo
    -- Retrieves information (e.g., serial number, issuer, expiration date) from a digital certificate.
    pub.security.util:loadPKCS7CertChain
    -- Converts a certificate chain that is in PKCS7 format to a list (a one-dimensional array) of byte arrays.
    Example:
    Invoke pub.client:http to send data to Company D.
    Invoke pub.security:setKeyAndChain using the key and certificate chain for Company B.
    Invoke pub.client:http to send data to Company B.
    Invoke pub.security:setKeyAndChain using the key and certificate chain for Company C.
    Invoke pub.client:http to send data to Company C.
    Invoke pub.security:clearKeyAndChain to revert back to the default key and certificate chain for Company
    Au2019s server.
    Invoke pub.client:http to send data to Company D.
    Edited by: Kai Lerch-Baier on Aug 3, 2009 1:47 PM

  • The request failed with HTTP status 404: Not Found

    Hi
    BPC version we are using is : 5.0.502
    When we  Publish all reports using the steps below:
    a. Log into BPC Web
    b. Click on Available Interfaces> Select BPC for Administration
    c. Under Web Admin Task Click Publish Reports
    d. Select all of the reports and click the green check mark to publish the
    reports.
    I am getting following message 'System.Exception: The request failed with HTTP Status 404: Not Found. Event log relation to this error is given below.
    Event Type:     Error
    Event Source:     OutlookSoft log
    Event Category:     None
    Event ID:     0
    Date:          12/8/2008
    Time:          11:26:42 AM
    User:          N/A
    Computer:     BPCAPP
    Description:
    ==============[System Error Tracing]==============
    [System  Name] : OSoftCPM
    [Message Type] : ErrorMessage
    [Job Name]     : AuditMgrService/SetAuditReportFiles
    [DateTime]     : 12/8/2008 11:26:42 AM
    [UserId]       : MMPlanning
    [Exception]
        DetailMsg  : {The request failed with HTTP status 404: Not Found.}
    ==============[System Error Tracing  End ]==============
    For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.
    We tried ' Publish all reports' as the resolution of error 'object variable or with block variable not set' on modifying an application as per sap note Note 1131320
    If anyone knows the resolution for the above issue, please help me.
    Thanks in advance
    Sajeev Abraham

    Hi
    Thanks for the response.
    Below are the full contents of the error message pop-up.
    ( System.Expection: the reguest failed with HTTP status 404:Not found at
    Microsoft.Visualbasic.CompierServices.lateBinding.LateGet(Object o, Type,String name, Object
    []args,sTRING[]paramnames, Boolen[]CopyBack)
    at OSoft.Services.WebServices.ReportmanageProxy.ReportManageProxy.SetPubishReport(String strAppSet,string
    strApp,string strFiter)
    url is given below
    http://<HostName>/osoft/Admin/WebAdminMain.aspx
    BPC Deployment is Multiple server ( Two servers) Database and Application deployed seperately.
    Sql Reporting server is working.. I could connect using sql management studio.
    Thanks

  • Error: on clicking Registry menu item in ESM Management Portal. The request failed with HTTP status 404: Not Found.

    Hi,
    I have installed ESB Management Portal successfully after following all the steps. everything is working fine except when I click the Registry menu in the portal. I get an unhandled exception. The event viewer shows the below error "The request failed
    with HTTP status 404: Not Found."
    ================================================
    Event code: 3005 
    Event message: An unhandled exception has occurred. 
    Event time: 1/27/2015 5:56:10 PM 
    Event time (UTC): 1/27/2015 5:56:10 PM 
    Event ID: f7aedd39118845b79c17d3442a0d15a7 
    Event sequence: 54 
    Event occurrence: 1 
    Event detail code: 0 
    Application information: 
        Application domain: /LM/W3SVC/1/ROOT/ESB.Portal-1-130668549484455107 
        Trust level: Full 
        Application Virtual Path: /ESB.Portal 
        Application Path: C:\Projects\Microsoft.Practices.ESB\Source\Samples\Management Portal\ESB.Portal\ 
        Machine name: <Machine Name> 
    Process information: 
        Process ID: 4712 
        Process name: w3wp.exe 
        Account name: NT AUTHORITY\NETWORK SERVICE 
    Exception information: 
        Exception type: TargetInvocationException 
        Exception message: Exception has been thrown by the target of an invocation.
       at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
       at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
       at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
       at System.Web.UI.WebControls.ObjectDataSourceView.InvokeMethod(ObjectDataSourceMethod method, Boolean disposeInstance, Object& instance)
       at System.Web.UI.WebControls.ObjectDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments)
       at System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback)
       at System.Web.UI.WebControls.DataBoundControl.PerformSelect()
       at System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound()
       at System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls()
       at System.Web.UI.Control.EnsureChildControls()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    The request failed with HTTP status 404: Not Found.
       at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
       at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
       at Microsoft.Practices.ESB.Portal.UDDIService.UDDIService.GetCategoryByName(String UDDIServerUrl, String tModelName) in c:\Projects\Microsoft.Practices.ESB\Source\Samples\Management Portal\ESB.Portal\Web References\UDDIService\Reference.cs:line
    575
       at Microsoft.Practices.ESB.Portal.Uddi.ServiceProxy.getBTEndpoints(String applicationName, Boolean getSendPorts, Boolean getRcvLocations) in c:\Projects\Microsoft.Practices.ESB\Source\Samples\Management Portal\ESB.Portal\Uddi\ServiceProxy.cs:line
    553
       at Microsoft.Practices.ESB.Portal.Uddi.ServiceProxy.GetEndpointsByApplication(String applicationName, Boolean getSendPorts, Boolean getRcvLocations) in c:\Projects\Microsoft.Practices.ESB\Source\Samples\Management Portal\ESB.Portal\Uddi\ServiceProxy.cs:line
    46
    Request information: 
        Request URL: http://localhost/ESB.Portal/uddi/uddi.aspx 
        Request path: /ESB.Portal/uddi/uddi.aspx 
        User host address: ::1 
        User: <domain>\<user>
        Is authenticated: True 
        Authentication Type: Negotiate 
        Thread account name: NT AUTHORITY\NETWORK SERVICE 
    Thread information: 
        Thread ID: 19 
        Thread account name: NT AUTHORITY\NETWORK SERVICE 
        Is impersonating: False 
        Stack trace:    at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
       at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
       at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
       at System.Web.UI.WebControls.ObjectDataSourceView.InvokeMethod(ObjectDataSourceMethod method, Boolean disposeInstance, Object& instance)
       at System.Web.UI.WebControls.ObjectDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments)
       at System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback)
       at System.Web.UI.WebControls.DataBoundControl.PerformSelect()
       at System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound()
       at System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls()
       at System.Web.UI.Control.EnsureChildControls()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    Custom event details: 
    =================================
    Any idea why this is happening and what needs to be done ?
    PLEASE HELP
    Thanks & Regards
    Vikram

    Snippet from the link below:
    If you get a “404: Not Found” error, it ‘s because by default there is no script map for .svc file with default IIS 7.0 installation, so you need to register .svc extension in IIS:
    You need to update IIS script maps to register .svc extension In a command prompt (ran as administrator), execute the following command:
    “%windir%\Microsoft.NET\Framework\v3.0\Windows Communication Foundation\ServiceModelReg.exe” -r -y"
    Refer:
    https://dgoins.wordpress.com/2010/05/01/esb-toolkit-management-portal-installation-notes-from-the-field-2/
    Sarvanan's blog around this with detailed explanation:
    Configuring Exception Management Portal
    As mentioned above also
    Check Portal Configuration Settings
    Rachit
    Please mark as answer or vote as helpful if my reply does

Maybe you are looking for

  • IPad4/iPhone5 won't print anymore

    When I first got the iPhone5 and iPad4, they came with IOS6. At that time they worked just fine with my CM1415fnw color LaserJet MFC. But that stopped once they got updated to IOS6.0.1. Now all I get is a printer halt saying that the paper won't feed

  • Goods Issue with cost

    Hello I am trying to make a goods issue to adjust the inventory, but i want to make it with the real cost of the product. I have just made a formated search to get the cost of the product, the problem is that if i select the last purchase price list,

  • Bulk Swatch Changing

    I hope I describe this right - I have a document, and have a large list of swatches (some global colors, some patterns)  I would like to know if I can save multiple variations for different color libraries, and somehow apply them when needed. I curre

  • Problem LR 5 Using HDR

    I just installed LR 5 and want to process an HDR photo in CS 5.  When I select CS 5 on the "Edit In" the HDR option is greyed out.  If I try to just process a photo in CS 5 I get a message that "This version of Lightroom may require the Photoshop Cam

  • Restored drive from image, now win7 does check disk ? as part of each boot

    Hi, I swapped my HDD for a SDD and restored an image of the old HDD to set up the new system. Now each time windows 7 boots, it does some type of check on the disk (moves fairly quickly, not exactly sure what its says: goes from the starting windows