Hi all,
I have a Flex application to authenticate with server via RemoteObject.
It is working normally with http (i.e. amf channel)
However when I try to login via https, the first access time, Flex application always return Fault error. Subsequent login is OK.
From server side, I see user has been logged in successfully at first time.
Is it because the certificate is not trusted? Any idea?
Thank you,
Anh
This is the log that I have from client side:
LoginCommand Fault: (mx.rpc.events::FaultEvent)#0
bubbles = false
cancelable = true
currentTarget = (null)
eventPhase = 2
fault = (mx.rpc::Fault)#1
content = (Object)#2
errorID = 0
faultCode = "Client.Error.MessageSend"
faultDetail = "Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed: url: 'https://172.52.22.218:9443/MyApplication/messagebroker/amfsecure'"
faultString = "Send failed"
message = "faultCode:Client.Error.MessageSend faultString:'Send failed' faultDetail:'Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed: url: 'https://172.52.22.218:9443/MyApplication/messagebroker/amfsecure''"
name = "Error"
rootCause = (mx.messaging.events::ChannelFaultEvent)#3
bubbles = false
cancelable = false
channel = (mx.messaging.channels::SecureAMFChannel)#4
authenticated = false
channelSets = (Array)#5
connected = false
connectTimeout = -1
enableSmallMessages = true
endpoint = "https://172.52.22.218:9443/MyApplication/messagebroker/amfsecure"
failoverURIs = (Array)#6
id = (null)
mpiEnabled = false
netConnection = (flash.net::NetConnection)#7
client = (mx.messaging.channels::SecureAMFChannel)#4
connected = false
objectEncoding = 3
proxyType = "none"
uri = "https://172.52.22.218:9443/MyApplication/messagebroker/amfsecure"
piggybackingEnabled = false
polling = false
pollingEnabled = true
pollingInterval = 3000
protocol = "https"
reconnecting = false
recordMessageSizes = false
recordMessageTimes = false
requestTimeout = -1
uri = "https://172.52.22.218:9443/MyApplication/messagebroker/amfsecure"
url = "https://172.52.22.218:9443/MyApplication/messagebroker/amfsecure"
useSmallMessages = false
channelId = (null)
connected = false
currentTarget = (mx.messaging.channels::SecureAMFChannel)#4
eventPhase = 2
faultCode = "Channel.Connect.Failed"
faultDetail = "NetConnection.Call.Failed: HTTP: Failed: url: 'https://172.52.22.218:9443/MyApplication/messagebroker/amfsecure'"
faultString = "error"
reconnecting = false
rejected = false
rootCause = (Object)#8
code = "NetConnection.Call.Failed"
description = "HTTP: Failed"
details = "https://172.52.22.218:9443/MyApplication/messagebroker/amfsecure"
level = "error"
target = (mx.messaging.channels::SecureAMFChannel)#4
type = "channelFault"
headers = (null)
message = (mx.messaging.messages::ErrorMessage)#9
body = (Object)#2
clientId = (null)
correlationId = "F4E42A7F-5E56-B704-CDB6-87826108D443"
destination = ""
extendedData = (null)
faultCode = "Client.Error.MessageSend"
faultDetail = "Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed: url: 'https://172.52.22.218:9443/MyApplication/messagebroker/amfsecure'"
faultString = "Send failed"
headers = (Object)#10
messageId = "B549C02F-9EDF-7C6E-C89F-878261572A73"
rootCause = (mx.messaging.events::ChannelFaultEvent)#3
timestamp = 0
timeToLive = 0
messageId = "B549C02F-9EDF-7C6E-C89F-878261572A73"
statusCode = 0
target = (null)
token = (mx.rpc::AsyncToken)#11
message = (mx.messaging.messages::RemotingMessage)#12
body = (Array)#13
[0] (com.mydomain.model.dto::LoginDTO)#14
statuscode = "0"
userName = "myusername"
clientId = (null)
destination = ""
headers = (Object)#15
messageId = "F4E42A7F-5E56-B704-CDB6-87826108D443"
operation = "authenticate"
source = (null)
timestamp = 0
timeToLive = 0
responders = (Array)#16
[0] (com.mydomain.controller::LoginCommand)#17
result = (null)
type = "fault"
Views
Replies
Total Likes
Hi. Are you using Internet Explorer? If so, have you set add-no-cache-headers to false on the endpoint?
With Internet Explorer you need to set the add-no-cache-headers property to false in the configuration settings for your endpoint in the services-config.xml file.
<add-no-cache-headers>false</add-no-cache-headers>
If that's not the issue please let me know which browser (and what version of the browser) you are testing with and which version of LiveCycle Data Services you are using and I will look into it further. Thanks.
-Alex
Views
Replies
Total Likes
Hi Alex,
Thank you for your reply. It is true that I failed in IE 6, 7, 8 with amf-secure channel. Firefox and Google Chrome is working.
I have checked the services-config.xml (should be the default) and see the <add-no-cache-headers>false</add-no-cache-headers> in channel definition my-secure-amf:
<!-- Secure Servlet-based endpoints -->
<channel-definition id="my-secure-amf" class="mx.messaging.channels.SecureAMFChannel">
<endpoint url="https://{server.name}:{server.port}/{context.root}/messagebroker/amfsecure" class="flex.messaging.endpoints.SecureAMFEndpoint"/>
<properties>
<!--HTTPS requests on some browsers do not work when pragma "no-cache" are set-->
<add-no-cache-headers>false</add-no-cache-headers>
</properties>
</channel-definition>
For my-amf, it is set to true
<!-- Servlet Based endpoints -->
<channel-definition id="my-amf" class="mx.messaging.channels.AMFChannel">
<endpoint url="http://{server.name}:{server.port}/{context.root}/messagebroker/amf" class="flex.messaging.endpoints.AMFEndpoint"/>
<properties>
<polling-enabled>false</polling-enabled>
<add-no-cache-headers>true</add-no-cache-headers>
<invalidate-session-on-disconnect>true</invalidate-session-on-disconnect>
</properties>
</channel-definition>
Is there any other place I need to add the add-no-cache-headers?
I'm using Websphere application, do I need to set any properties in Websphere?
Thank you and look forward to your reply,
Anh
Views
Replies
Total Likes
By the way, I'm using LCDS 2.6
does the error relate to attribute CookiesConfigureNoCache in Websphere HTTP Channel?
Regards,
Anh
Views
Replies
Total Likes
Hi,
My current workaround solution is to invoke a remote object when the application is loaded. After this invocation, the connection is setup properly.
Thank you and regards,
Anh
Views
Replies
Total Likes
Alex,
I agree with your statement about setting the "add-no-cache-headers: property to false, but my question is why do we need to do that. Microsoft's IE website states that the only reason we should need to do this is if IE is attempting to read a file on a remote server, like downloading a spreadsheet. What is Flex/ActionScript putting on the server that IE thinks it needs to read so that it can receive the response from BlazeDS?
WCE 2
Views
Replies
Total Likes
Hi,
I am currently facing the same problem: trying to use SecureAMFChannel only but connection fails.
I didn't try the workaround yet. Is there any real solution to this problem ? did we misunderstand the way to use/configure blazeds ?
Here is the default section of services-config.xml about channels:
<channel-definition id="my-secure-amf" class="mx.messaging.channels.SecureAMFChannel">
<endpoint url="https://{server.name}:{server.port}/{context.root}/messagebroker/amfsecure" class="flex.messaging.endpoints.SecureAMFEndpoint"/>
<properties>
<add-no-cache-headers>false</add-no-cache-headers>
</properties>
</channel-definition>
You will notice that <add-no-cache-headers> is already set to false.
Tests failed on Chrome 6. Everything is ok if I use basic AMF.
Views
Replies
Total Likes
Hi,
I am still having an issue with IE even though I have added
<add-no-cache-headers>false</add-no-cache-headers>
Can you please let me know How to resolve this issue?
Thanks
Shardul
Views
Replies
Total Likes
Hi,
In my case, the problem was an IT infrastructure design one.
Therefore I don't think I can help you !
Good luck !
Envoyé de mon mobile
Le 8 févr. 2011 à 22:52, sharduldkhatri <forums@adobe.com> a écrit :
Hi,
>
I am still having an issue with IE even though I have added
<add-no-cache-headers>false</add-no-cache-headers>
Can you please let me know How to resolve this issue?
>
Thanks
>
Shardul
>
Views
Replies
Total Likes
Can you elaborate the infrastructure issue?
Thanks
Shardul
Views
Replies
Total Likes
The design of the network blocked the service calls through firewalls
and flows balancers.
Envoyé de mon mobile
Le 9 févr. 2011 à 00:28, sharduldkhatri <forums@adobe.com> a écrit :
Can you elaborate the infrastructure issue?
>
Thanks
>
Shardul
>
Views
Replies
Total Likes
We have the same design. What solution did you apply.
Thanks
Shardul
Views
Replies
Total Likes