Page 1 of 2 12 LastLast
Results 1 to 10 of 14
  1. #1
    Member
    Join Date
    Aug 2007
    Location
    Bangalore
    Posts
    11

    HTTPS & Flex Client

    Hi.. I am using Flex Native AS client which works fine over HTTP. Now I am trying to set it up over HTTPS. I ve done the following.

    1. Modified lightstreamer_conf.xml, removed <http_server> and included <https_server> block with default parameters.
    2. On the client side, modified the ConnectionInfo parameters to change the port, controlPort and the corresponding protocols.

    When I try to access the flex page over https, I see the page being loaded but streaming doesnt happen. On the server side, I see a new session being created after invoking the notifyUser method on the MetadataAdapter but getItems or getSchema methods are not invoked. Am I missing something here?

    Regards,
    Venkatesan R

  2. #2
    Power Member
    Join Date
    Jul 2006
    Location
    Cesano Maderno, Italy
    Posts
    784
    Hi Venkihere,

    to let a Flex application downloaded through http access a web server over SSL, you must specify a secure=false attribute to the allow-access-from element in your crossdomain.xml file.
    So in example, if your flex movie is downloaded via http://www.mycompany.com/ and you want to connect to Lightstreamer through https://push.mycompany.com/ an allow-access-from policy like the one below is not enough:

    you need something like this:


    Hope that helps.

  3. #3
    Member
    Join Date
    Aug 2007
    Location
    Bangalore
    Posts
    11
    Hi.. Thank you for the reply.. But the page was downloaded over https..

  4. #4
    Power Member
    Join Date
    Jul 2006
    Location
    Cesano Maderno, Italy
    Posts
    784
    Sorry...
    Please could you describe
    1. Your environment (how do you access web server and Lightstreamer server)
    2. Your crossdomain.xml file
    3. You ConnectionInfo configuration

  5. #5
    Member
    Join Date
    Aug 2007
    Location
    Bangalore
    Posts
    11
    Quote Originally Posted by Mone
    1. Your environment (how do you access web server and Lightstreamer server)
    I ve placed my flex page in the pages folder of lightstreamer. In lightstreamer_conf.xml, I ve enabled only the ssl server. I am accessing the page using a https url.
    Quote Originally Posted by Mone
    Your crossdomain.xml file
    <cross-domain-policy>
    <allow-access-from domain="*" />
    </cross-domain-policy>

    Quote Originally Posted by Mone
    You ConnectionInfo configuration
    var cInfo:ConnectionInfo = new ConnectionInfo();
    cInfo.setServer("push.mydomain.com");
    cInfo.setAdapter("STOCKLISTDEMO");
    cInfo.setControlPort(443);
    cInfo.setPort(443);
    cInfo.setControlProtocol("https");
    cInfo.setProtocol("https");
    cInfo.setUser("TEST_USER");
    cInfo.setPassword("TEST_USER");

  6. #6
    Power Member
    Join Date
    Jul 2006
    Location
    Cesano Maderno, Italy
    Posts
    784
    As a first view everything seems correct.

    Are you able to run the standard StockListDemo (i.e. the html one) over SSL on your server?

  7. #7
    Member
    Join Date
    Aug 2007
    Location
    Bangalore
    Posts
    11
    Yeah.. The html stocklistdemo works over https..

  8. #8
    Power Member
    Join Date
    Jul 2006
    Location
    Cesano Maderno, Italy
    Posts
    784
    Hi,

    It's pretty strange.
    Please check your server logs, do you see control connections (control.txt requests)?
    Paste the log of a problematic session if possible.

  9. #9
    Member
    Join Date
    Aug 2007
    Location
    Bangalore
    Posts
    11
    Sorry for the delay.. I dont see any control requests.. only the following info gets logged periodically..

    11.Oct.07 18:06:45,306 < INFO> Serving request: /lightstreamer/create_session.txt?LS_user=TEST_USER&LS_password=T EST_USER&LS_adapter=STOCKLISTD
    EMO&LS_polling=true&LS_polling_millis=500&LS_idle_ millis=30000&LS_report_info=true& from 172.16.161.120:3693
    11.Oct.07 18:06:45,306 <TRACE> Max allowed bandwidth for user TEST_USER = 0.0 Kbit/sec
    11.Oct.07 18:06:45,306 <TRACE> Applying slowing factor of 1.0
    11.Oct.07 18:06:45,306 < INFO> Starting new session: S-1513054843N6 from 172.16.161.120:3693
    11.Oct.07 18:06:45,306 < INFO> Reused HTTPS connection on Lightstreamer HTTPS Server from 172.16.161.120:3693

  10. #10
    Power Member
    Join Date
    Jul 2006
    Location
    Cesano Maderno, Italy
    Posts
    784
    I can't understand what is wrong with your app, so I do a little recap, let me know if you see something different from your conf.

    My Lightstreamer server is on mone.lightstreamer.com (no it's not on the internet)

    This is my Lightstreamer_conf.xml file (obviously is full of not-related-to-this-thread settings):


    myserver.keystore is the keystore file shipped with Lightstreamer.

    This is my crossdomain.xml file:

    I've placed my application under the pages directory of Lightstreamer.
    This is the source code of the application:

    The adapter is the StockListDemo adapter as shipped with Lightstreamer.
    My server version is 3.4.4 build 1362.

    I open the application with this url: https://mone.lightstreamer.com/fl/a.swf
    I obviously can see the pushed values.
    Can you see any differnces?

 

 

Similar Threads

  1. LS Flex Client is stalled on restart of LS server
    By pratik in forum Client SDKs
    Replies: 4
    Last Post: June 26th, 2015, 09:56 AM
  2. Replies: 1
    Last Post: July 12th, 2010, 11:05 AM
  3. Problem running Flex examples
    By markgoldin in forum Client SDKs
    Replies: 10
    Last Post: May 26th, 2008, 09:52 AM
  4. Flex Client API now generally available
    By Alessandro in forum Client SDKs
    Replies: 0
    Last Post: September 3rd, 2007, 05:23 PM
  5. Flex Demo Released
    By Alessandro in forum Client SDKs
    Replies: 0
    Last Post: July 24th, 2007, 06:02 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT +1. The time now is 06:57 PM.