You are here

protected function CasLogout::destroySession in CAS 2.x

Same name and namespace in other branches
  1. 8 src/Service/CasLogout.php \Drupal\cas\Service\CasLogout::destroySession()

Load up the session and destroy it.

@codeCoverageIgnore

Parameters

string $sid: The ticket id to destroy.

1 call to CasLogout::destroySession()
CasLogout::handleSlo in src/Service/CasLogout.php
Handles a single-log-out request from a CAS server.

File

src/Service/CasLogout.php, line 103

Class

CasLogout
Provides a default implementation for 'cas.logout' service.

Namespace

Drupal\cas\Service

Code

protected function destroySession($sid) {
  session_id($sid);
  session_start();
  session_destroy();
  session_write_close();
}