Return-Path: X-Original-To: apmail-cxf-users-archive@www.apache.org Delivered-To: apmail-cxf-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 5FA129989 for ; Mon, 25 Jun 2012 14:02:43 +0000 (UTC) Received: (qmail 50139 invoked by uid 500); 25 Jun 2012 14:02:42 -0000 Delivered-To: apmail-cxf-users-archive@cxf.apache.org Received: (qmail 50082 invoked by uid 500); 25 Jun 2012 14:02:42 -0000 Mailing-List: contact users-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@cxf.apache.org Delivered-To: mailing list users@cxf.apache.org Received: (qmail 50073 invoked by uid 99); 25 Jun 2012 14:02:42 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Jun 2012 14:02:42 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS,WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of himanshu.kgp@gmail.com designates 209.85.212.171 as permitted sender) Received: from [209.85.212.171] (HELO mail-wi0-f171.google.com) (209.85.212.171) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Jun 2012 14:02:36 +0000 Received: by wibhq4 with SMTP id hq4so2666989wib.6 for ; Mon, 25 Jun 2012 07:02:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=Z8m4NLVH/e+3+dNG5bJVS7aIrMgKY+vV8D8yEB2Tjmc=; b=CdHT8TQSH2XAu6f/+mtWyEJO7j0bHXOJIyDJ5UOPTr//I16smS+zhFoCKAEQWcrSNx InwvHqDKdPrZc1REZXsaQLt6l4m7PG7xdtDBwstMEmovrgDYLf66vdsN8mOIpPIQ4Ltg iM8DgQ+QcP0nB8U9ZXc9dF2/D3KFUv0nQs2lW9FKb6hfZqAThqMjRfrd7kDVbrefSQBk SYhLNGcUaumLrTDdl+M8SxJ7SraAODKUraTxjIHYbdmO2/ne07QvCKRFPmPSMEPowwg0 4ndaYG6TwQjybflza1dWEMBoJID8ojJVs5nuPjBcudnn1M0IEoZyf9PYkaIsjE+/ePnc JrgQ== MIME-Version: 1.0 Received: by 10.180.82.198 with SMTP id k6mr25272917wiy.20.1340632934913; Mon, 25 Jun 2012 07:02:14 -0700 (PDT) Received: by 10.223.122.68 with HTTP; Mon, 25 Jun 2012 07:02:14 -0700 (PDT) In-Reply-To: References: <4FE85ED3.7000708@talend.com> Date: Mon, 25 Jun 2012 16:02:14 +0200 Message-ID: Subject: Re: wsdl_first_https From: Himanshu Gupta To: users@cxf.apache.org, coheigea@apache.org Content-Type: multipart/alternative; boundary=f46d04428d9cdc185904c34c6deb X-Virus-Checked: Checked by ClamAV on apache.org --f46d04428d9cdc185904c34c6deb Content-Type: text/plain; charset=ISO-8859-1 Hello Colm, In the sample wsdl_first_https, I removed line from the server configuration. The Client in the example works well. But the Firefox fails, and still gives error "javax.net.ssl.SSLHandshakeException: no cipher suites in common" on the server. Please let me know, If you want me to try something specific. Sorry just looking for an appropriate solution :( Thanks, Himanshu. On Mon, Jun 25, 2012 at 3:57 PM, Colm O hEigeartaigh wrote: > > Colm : I did add the certificates to for e.g. in the Firefox explicitly. > > Yes, you added the certificates so that the browser trusted the service > endpoint. However, as I explained in my previous mail, the service endpoint > requires that the client presents its own certificate + private key for > client authentication, hence the failure. > > Colm. > > On Mon, Jun 25, 2012 at 2:51 PM, Himanshu Gupta >wrote: > > > Hello Guys, > > > > Colm : I did add the certificates to for e.g. in the Firefox explicitly. > > > > Following > http://aruld.info/programming-ssl-for-jetty-based-cxf-services/ for > > my Dynamic Client, I try to do somthing like below : > > > > 1. JaxWsDynamicClientFactory dcf = > JaxWsDynamicClientFactory.newInstance(); > > 2. Client client = dcf.createClient(" > > > https://localhost:9001/ApexCollateral/ing/services/wss/agreementDemo/2.0?wsdl > > "); > > 3. configureSSLOnTheClient(client); > > 4. Object[] res = client.invoke("getAgreementDemoIdentifier", new > > Integer(1)); > > > > Theoretically it should have worked, but it fails with an exception like > > "org.apache.cxf.service.factory.ServiceConstructionException: Could not > > resolve URL "https://localhost:9001/someService/2.0?wsdl".", while > > excetuing *line number 2 (*logs attached*) *that is even before line 3 > > where I could setup the truststore, manually. > > > > I really want to use the Dynamic Client approach in the test cases to > test > > my web services. I assume, along with the testing services, with this > > approach I also validate auto code generation for clients, which would be > > used eventually by the consumers (by exposed wsdls). > > > > Please help, > > > > Thanks, > > Himanshu. > > > > > > On Mon, Jun 25, 2012 at 2:51 PM, Glen Mazza wrote: > > > >> Personally, for SSL, I would recommend using a standalone servlet > >> container like Tomcat to host your web service ( > http://www.jroller.com/** > >> gmazza/entry/ssl_for_web_**services< > http://www.jroller.com/gmazza/entry/ssl_for_web_services>), > >> I wouldn't rely on Endpoint.publish() for production, especially if > you're > >> using SSL. > >> > >> For your dynamic client, as the link above mentions, the certs will need > >> to be in the "cacerts" file used by the JRE that is running the dynamic > >> client--or another truststore file that you configure--the browser is > >> irrelevant as it's not being used there. > >> > >> HTH, > >> Glen > >> > >> > >> On 06/25/2012 07:46 AM, Himanshu Gupta wrote: > >> > >>> Hello Experts, > >>> > >>> Quite new to CXF, having a usecase where I need to expose our existing > >>> services as webservices. App is a standalone server, so am using > embedded > >>> jetty with https. Everything works fine, except that when I hit the > >>> server > >>> with the wsdl url through a browser (any browser), I get > >>> "javax.net.ssl.**SSLHandshakeException: no cipher suites in common". > >>> > >>> This could be reproduced if you just run the wsdl_first_https server > and > >>> hit the url https://localhost:9001/**SoapContext/SoapPort?wsdl< > https://localhost:9001/SoapContext/SoapPort?wsdl>. > >>> Please help > >>> escape this problem. > >>> > >>> Also the client in the wsdl_first_https works. But if I try to use the > >>> Dynamic Client (thats a requirement), it fails as well, as it could not > >>> find the wsdl. The Dynamic client looks somthing like below : > >>> > >>> > >>> JaxWsDynamicClientFactory dcf = JaxWsDynamicClientFactory.** > >>> newInstance(); > >>> Client client = dcf.createClient(" > >>> https://localhost:443/**someservice/2.0?wsdl< > https://localhost:443/someservice/2.0?wsdl> > >>> https://localhost/someservice/2.0?wsdl> > >>> **> > >>> > >>> "); > >>> Object[] res = client.invoke(jnew > >>> QName("http://someNameSpace/ http://somenamespace/> > >>> >", > >>> > >>> "getSomeIdentifier"), new Integer(1)); > >>> > >>> PS : I have already tried adding the certs to the browser. > >>> > >>> Thanks in Advance, > >>> > >>> > >> > >> -- > >> Glen Mazza > >> Talend Community Coders > >> coders.talend.com > >> blog: www.jroller.com/gmazza > >> > >> > > > > > > -- > > Himanshu Gupta. > > > > > > -- > Colm O hEigeartaigh > > Talend Community Coder > http://coders.talend.com > -- Himanshu Gupta. --f46d04428d9cdc185904c34c6deb--