• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Check SSL
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Check SSL


  • Subject: Re: Check SSL
  • From: Andrew Lindesay <email@hidden>
  • Date: Mon, 19 May 2008 20:42:20 +1200

WO 5.4;

	WORequest.isSecure()

WO 5.3.3;

public static boolean isRequestTransportedSecurely(WORequest request)
{
if(null==request)
throw new IllegalArgumentException("a non-null request must be supplied in order to establish if it's secure or not.");


		String secureFlagS = request.headerForKey("https");

		if(null!=secureFlagS)
			return LEStringHelper.booleanForString(secureFlagS);
		else
		{
			String serverPortS = request.headerForKey("server_port");

			if(null!=serverPortS)
			{
				try { return (443==Integer.parseInt(serverPortS)); }
				catch(NumberFormatException nfe) { /* ignore */ }
			}

String servletServerPortS = request.headerForKey("x-webobjects- servlet-server-port");

			if(null!=servletServerPortS)
			{
				try { return (443==Integer.parseInt(servletServerPortS)); }
				catch(NumberFormatException nfe) { /* ignore */ }
			}
		}

		return false;
	}

cheers.

I've made a Direct Action that make authentication, but I need that the communication between the client-server is secure, under SSL.
Is there a way to check if the request was sent under SSL?l

___ Andrew Lindesay www.lindesay.co.nz

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Check SSL (From: "Daniele Corti" <email@hidden>)

  • Prev by Date: Check SSL
  • Next by Date: ReportGeneration problem
  • Previous by thread: Check SSL
  • Next by thread: Re: Check SSL
  • Index(es):
    • Date
    • Thread