Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Session Logout with Curl


Go to End


2 Posts   1266 Views

Avatar
Praveen

Community Member, 49 Posts

19 May 2015 at 6:39pm

Edited: 19/05/2015 6:41pm

I'm having multiple application and I trying to have single signon and singout.
The below culr does not signout SS when executed from another application, there is no errors and the response returns 1.

               
$curl = curl_init();
		curl_setopt ( $curl, CURLOPT_URL, $Domain . 'Security/Logout/' );
		curl_setopt ( $curl, CURLOPT_POST, false );
		curl_setopt ( $curl, CURLOPT_RETURNTRANSFER, false );
		curl_setopt ( $curl, CURLOPT_HEADER, false );
		curl_setopt ( $curl, CURLOPT_USERAGENT, $_SERVER['HTTP_USER_AGENT'] );
               $result = curl_exec ( $curl );
              //returns 1
             Not logout out

Thanks
B L Praveen

Avatar
Praveen

Community Member, 49 Posts

19 May 2015 at 6:45pm

I traced to Security Page . It seems that there is on member session exists. As the two applications are in different servers