You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Alistair Young <al...@smo.uhi.ac.uk> on 2007/11/01 12:29:13 UTC

[AXIS2] custom https handler : Transport out has not been set

I'd like to remap https to another "name", e.g. "secure" as I want to  
use custom ssl handling with it. I've done this:

Protocol authhttps = new Protocol("secure", new  
FedoraProtocolSocketFactory(keystoreLocation, keystorePassword,  
truststoreLocation, truststorePassword, 443);
Protocol.registerProtocol("secure", authhttps);

it works fine using "https" but when I change it to "secure" I get  
the error:

"Transport out has not been set"

when connecting to secure://service.url

is there a way to tell Axis2 how to handle "secure" - it's really  
https in disguise

thanks,

Alistair



--------------
mov eax,1
mov ebx,0
int 80h





Re: [AXIS2] custom https handler : Transport out has not been set

Posted by Alistair Young <al...@smo.uhi.ac.uk>.
yes, it's 1.3. I use it via mvn:

<groupId>org.apache.axis2</groupId>
<artifactId>axis2-kernel</artifactId>
<version>1.3</version>

Alistair

-- 
mov eax,1
mov ebx,0
int 80h

>
> Hi,
>
> What is the Axis2 version you are using ? Did you try that with Axis2 1.3
> ?
>
>
> Best,
> --Sanka
>
>
> Alistair Young wrote:
>> is this a bug in Axis2? I followed the instructions at:
>>
>> http://wso2.org/library/1646:
>>
>> "You can provide a virtual protocol name to be used with your new
>> socket factory as well. In order to do this, you just have to register
>> your new protocol with HTTPClient. Nothing else is required to be
>> passed in to Axis engine"
>>
>> I did that but nothing works. I always get the error:
>>
>> "Transport out has not been set"
>>
>> Alistair
>>
>>
>> --------------
>> mov eax,1
>> mov ebx,0
>> int 80h
>>
>>
>>
>>
>> On 1 Nov 2007, at 11:50, Alistair Young wrote:
>>
>>> typo, it should be:
>>>
>>> Protocol authhttps = new Protocol("https", new
>>> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword,
>>> truststoreLocation, truststorePassword, 443);
>>> Protocol.registerProtocol("secure", authhttps);
>>>
>>> Axis2 uses HttpClient but doesn't seem to understand "secure" instead
>>> of "https". Registering "secure" as a protocol is enough for
>>> HttpClient but not Axis2. Is there another step I need to do to get
>>> Axis2 to work with "secure" protocol designator?
>>>
>>> thanks,
>>>
>>> Alistair
>>>
>>>
>>>
>>> --------------
>>> mov eax,1
>>> mov ebx,0
>>> int 80h
>>>
>>>
>>>
>>>
>>> On 1 Nov 2007, at 11:29, Alistair Young wrote:
>>>
>>>> I'd like to remap https to another "name", e.g. "secure" as I want
>>>> to use custom ssl handling with it. I've done this:
>>>>
>>>> Protocol authhttps = new Protocol("secure", new
>>>> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword,
>>>> truststoreLocation, truststorePassword, 443);
>>>> Protocol.registerProtocol("secure", authhttps);
>>>>
>>>> it works fine using "https" but when I change it to "secure" I get
>>>> the error:
>>>>
>>>> "Transport out has not been set"
>>>>
>>>> when connecting to secure://service.url
>>>>
>>>> is there a way to tell Axis2 how to handle "secure" - it's really
>>>> https in disguise
>>>>
>>>> thanks,
>>>>
>>>> Alistair
>>>>
>>>>
>>>>
>>>> --------------
>>>> mov eax,1
>>>> mov ebx,0
>>>> int 80h
>>>>
>>>>
>>>>
>>>>
>>>
>>
>
>
> --
> Sanka Samaranayake
> WSO2 Inc.
>
> http://www.bloglines.com/blog/sanka
> http://www.wso2.org/
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: [AXIS2] custom https handler : Transport out has not been set

Posted by Sanka Samaranayke <ss...@gmail.com>.
Hi,

What is the Axis2 version you are using ? Did you try that with Axis2 1.3 ?


Best,
--Sanka


Alistair Young wrote:
> is this a bug in Axis2? I followed the instructions at:
>
> http://wso2.org/library/1646:
>
> "You can provide a virtual protocol name to be used with your new 
> socket factory as well. In order to do this, you just have to register 
> your new protocol with HTTPClient. Nothing else is required to be 
> passed in to Axis engine"
>
> I did that but nothing works. I always get the error:
>
> "Transport out has not been set"
>
> Alistair
>
>
> --------------
> mov eax,1
> mov ebx,0
> int 80h
>
>
>
>
> On 1 Nov 2007, at 11:50, Alistair Young wrote:
>
>> typo, it should be:
>>
>> Protocol authhttps = new Protocol("https", new 
>> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword, 
>> truststoreLocation, truststorePassword, 443);
>> Protocol.registerProtocol("secure", authhttps);
>>
>> Axis2 uses HttpClient but doesn't seem to understand "secure" instead 
>> of "https". Registering "secure" as a protocol is enough for 
>> HttpClient but not Axis2. Is there another step I need to do to get 
>> Axis2 to work with "secure" protocol designator?
>>
>> thanks,
>>
>> Alistair
>>
>>
>>
>> --------------
>> mov eax,1
>> mov ebx,0
>> int 80h
>>
>>
>>
>>
>> On 1 Nov 2007, at 11:29, Alistair Young wrote:
>>
>>> I'd like to remap https to another "name", e.g. "secure" as I want 
>>> to use custom ssl handling with it. I've done this:
>>>
>>> Protocol authhttps = new Protocol("secure", new 
>>> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword, 
>>> truststoreLocation, truststorePassword, 443);
>>> Protocol.registerProtocol("secure", authhttps);
>>>
>>> it works fine using "https" but when I change it to "secure" I get 
>>> the error:
>>>
>>> "Transport out has not been set"
>>>
>>> when connecting to secure://service.url
>>>
>>> is there a way to tell Axis2 how to handle "secure" - it's really 
>>> https in disguise
>>>
>>> thanks,
>>>
>>> Alistair
>>>
>>>
>>>
>>> --------------
>>> mov eax,1
>>> mov ebx,0
>>> int 80h
>>>
>>>
>>>
>>>
>>
>


-- 
Sanka Samaranayake
WSO2 Inc.

http://www.bloglines.com/blog/sanka
http://www.wso2.org/


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: [AXIS2] custom https handler : Transport out has not been set

Posted by Alistair Young <al...@smo.uhi.ac.uk>.
is this a bug in Axis2? I followed the instructions at:

http://wso2.org/library/1646:

"You can provide a virtual protocol name to be used with your new  
socket factory as well. In order to do this, you just have to  
register your new protocol with HTTPClient. Nothing else is required  
to be passed in to Axis engine"

I did that but nothing works. I always get the error:

"Transport out has not been set"

Alistair


--------------
mov eax,1
mov ebx,0
int 80h




On 1 Nov 2007, at 11:50, Alistair Young wrote:

> typo, it should be:
>
> Protocol authhttps = new Protocol("https", new  
> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword,  
> truststoreLocation, truststorePassword, 443);
> Protocol.registerProtocol("secure", authhttps);
>
> Axis2 uses HttpClient but doesn't seem to understand "secure"  
> instead of "https". Registering "secure" as a protocol is enough  
> for HttpClient but not Axis2. Is there another step I need to do to  
> get Axis2 to work with "secure" protocol designator?
>
> thanks,
>
> Alistair
>
>
>
> --------------
> mov eax,1
> mov ebx,0
> int 80h
>
>
>
>
> On 1 Nov 2007, at 11:29, Alistair Young wrote:
>
>> I'd like to remap https to another "name", e.g. "secure" as I want  
>> to use custom ssl handling with it. I've done this:
>>
>> Protocol authhttps = new Protocol("secure", new  
>> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword,  
>> truststoreLocation, truststorePassword, 443);
>> Protocol.registerProtocol("secure", authhttps);
>>
>> it works fine using "https" but when I change it to "secure" I get  
>> the error:
>>
>> "Transport out has not been set"
>>
>> when connecting to secure://service.url
>>
>> is there a way to tell Axis2 how to handle "secure" - it's really  
>> https in disguise
>>
>> thanks,
>>
>> Alistair
>>
>>
>>
>> --------------
>> mov eax,1
>> mov ebx,0
>> int 80h
>>
>>
>>
>>
>


Re: [AXIS2] custom https handler : Transport out has not been set

Posted by Alistair Young <al...@smo.uhi.ac.uk>.
I did. I've tried every combination. I've tried registering the protocol
(Protocol.register) as a global handler - same error. I then unregistered
the protocol and added it to the service client - same error.

It all works fine if I use:

Protocol authhttps = new Protocol("https", new
FedoraProtocolSocketFactory(keystoreLocation, keystorePassword,
truststoreLocation, truststorePassword, 443);
Options options = serviceClient.getOptions();
optoins.|setProperty(HTTPConstants.CUSTOM_PROTOCOL_HANDLER,
authhttps);

if I use "secure" instead of "https" I get the error. Even if I
Protocol.register("secure", authhttps), the service client doesn't pick it
up and I get the error.

I wanted to use "secure" as I don't want to handle all HTTPS in this way.
However, if I don't register the handler but pass it direct to the service
client, it works fine, though only if I create the handler for "https".

I was doing what it says on this page:
http://wso2.org/library/1646

So I think the issue is the service client not picking up
Protocol.register or not understanding anything other than "https" as a
protocol designator?

thanks,

Alistair



-- 
mov eax,1
mov ebx,0
int 80h

> Alistair Young wrote:
>> typo, it should be:
>>
>> Protocol authhttps = new Protocol("https", new
>> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword,
>> truststoreLocation, truststorePassword, 443);
>> Protocol.registerProtocol("secure", authhttps);
>>
>> Axis2 uses HttpClient but doesn't seem to understand "secure" instead
>> of "https". Registering "secure" as a protocol is enough for
>> HttpClient but not Axis2. Is there another step I need to do to get
>> Axis2 to work with "secure" protocol designator?
>>
>> thanks,
>>
>> Alistair
>>
>>
>>
>> --------------
>> mov eax,1
>> mov ebx,0
>> int 80h
>>
>>
>>
>>
>> On 1 Nov 2007, at 11:29, Alistair Young wrote:
>>
>>> I'd like to remap https to another "name", e.g. "secure" as I want to
>>> use custom ssl handling with it. I've done this:
>>>
>>> Protocol authhttps = new Protocol("secure", new
>>> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword,
>>> truststoreLocation, truststorePassword, 443);
>>> Protocol.registerProtocol("secure", authhttps);
>
> try setting the following property in MessageContext or in Options and see
> whether you are getting the same error.
>
> e.g.
> Options options = serviceClient.getOptions();
> optoins.|setProperty(HTTPConstants.CUSTOM_PROTOCOL_HANDLER,
> myProtocolHandler);
>
>
> |
>
>>>
>>> it works fine using "https" but when I change it to "secure" I get
>>> the error:
>>>
>>> "Transport out has not been set"
>>>
>>> when connecting to secure://service.url
>>>
>>> is there a way to tell Axis2 how to handle "secure" - it's really
>>> https in disguise
>>>
>>> thanks,
>>>
>>> Alistair
>>>
>>>
>>>
>>> --------------
>>> mov eax,1
>>> mov ebx,0
>>> int 80h
>>>
>>>
>>>
>>>
>>
>
>
> --
> Sanka Samaranayake
> WSO2 Inc.
>
> http://www.bloglines.com/blog/sanka
> http://www.wso2.org/
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: [AXIS2] custom https handler : Transport out has not been set

Posted by Sanka Samaranayke <ss...@gmail.com>.
Alistair Young wrote:
> typo, it should be:
>
> Protocol authhttps = new Protocol("https", new 
> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword, 
> truststoreLocation, truststorePassword, 443);
> Protocol.registerProtocol("secure", authhttps);
>
> Axis2 uses HttpClient but doesn't seem to understand "secure" instead 
> of "https". Registering "secure" as a protocol is enough for 
> HttpClient but not Axis2. Is there another step I need to do to get 
> Axis2 to work with "secure" protocol designator?
>
> thanks,
>
> Alistair
>
>
>
> --------------
> mov eax,1
> mov ebx,0
> int 80h
>
>
>
>
> On 1 Nov 2007, at 11:29, Alistair Young wrote:
>
>> I'd like to remap https to another "name", e.g. "secure" as I want to 
>> use custom ssl handling with it. I've done this:
>>
>> Protocol authhttps = new Protocol("secure", new 
>> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword, 
>> truststoreLocation, truststorePassword, 443);
>> Protocol.registerProtocol("secure", authhttps);

try setting the following property in MessageContext or in Options and see whether you are getting the same error.

e.g.
Options options = serviceClient.getOptions();
optoins.|setProperty(HTTPConstants.CUSTOM_PROTOCOL_HANDLER, myProtocolHandler);


|

>>
>> it works fine using "https" but when I change it to "secure" I get 
>> the error:
>>
>> "Transport out has not been set"
>>
>> when connecting to secure://service.url
>>
>> is there a way to tell Axis2 how to handle "secure" - it's really 
>> https in disguise
>>
>> thanks,
>>
>> Alistair
>>
>>
>>
>> --------------
>> mov eax,1
>> mov ebx,0
>> int 80h
>>
>>
>>
>>
>


-- 
Sanka Samaranayake
WSO2 Inc.

http://www.bloglines.com/blog/sanka
http://www.wso2.org/



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: [AXIS2] custom https handler : Transport out has not been set

Posted by Alistair Young <al...@smo.uhi.ac.uk>.
typo, it should be:

Protocol authhttps = new Protocol("https", new  
FedoraProtocolSocketFactory(keystoreLocation, keystorePassword,  
truststoreLocation, truststorePassword, 443);
Protocol.registerProtocol("secure", authhttps);

Axis2 uses HttpClient but doesn't seem to understand "secure" instead  
of "https". Registering "secure" as a protocol is enough for  
HttpClient but not Axis2. Is there another step I need to do to get  
Axis2 to work with "secure" protocol designator?

thanks,

Alistair



--------------
mov eax,1
mov ebx,0
int 80h




On 1 Nov 2007, at 11:29, Alistair Young wrote:

> I'd like to remap https to another "name", e.g. "secure" as I want  
> to use custom ssl handling with it. I've done this:
>
> Protocol authhttps = new Protocol("secure", new  
> FedoraProtocolSocketFactory(keystoreLocation, keystorePassword,  
> truststoreLocation, truststorePassword, 443);
> Protocol.registerProtocol("secure", authhttps);
>
> it works fine using "https" but when I change it to "secure" I get  
> the error:
>
> "Transport out has not been set"
>
> when connecting to secure://service.url
>
> is there a way to tell Axis2 how to handle "secure" - it's really  
> https in disguise
>
> thanks,
>
> Alistair
>
>
>
> --------------
> mov eax,1
> mov ebx,0
> int 80h
>
>
>
>