Удаляет сессию по идентификатору.
@param string $sessionId
@return $this
436427
public function deleteSession(string $sessionId)
    {
        $this->curl(
            $this->factoryCommand(
                "session/{$sessionId}",
                \WebDriver_Command::METHOD_DELETE
            )
        );
        return $this;
    }
1210925
public function destroy($session_id)
    {
        $result = false;

        if ($this->getTable()->isConnected())
        {
            $row = $this->_table->select($session_id, KDatabase::FETCH_ROW);

            if (!$row->isNew()) {
                $result = $row->delete();
            }
        }

        return $result;
    }
234206
public function read($sessionId) {
        try {
            // try to retrieve the session content first to see if it exists
            $result = $this->_tableRestProxy->getEntity($this->_sessionContainer, $this->_sessionContainerPartition, $sessionId);
            // get the entity instance
            $entity = $result->getEntity();
            // deflat the serialized data
            return unserialize(base64_decode($entity->getPropertyValue('data')));
        } catch (ServiceException $e) {
            // the entity doesn't exist, return empty string according to the spec:
            //   http://www.php.net/manual/en/sessionhandlerinterface.read.php
            return '';
        }
    }
487850
public function __tearup($sessionId = null)
    {
        $configuration = self::getRegistry()->getConfiguration()->session;

        $this
            ->logger(self::getRegistry()->getLogging())
            ->id($sessionId)
            ->clientIp($_SERVER['REMOTE_ADDR'])
            ->userAgent($_SERVER['HTTP_USER_AGENT'])
            ->domain($_SERVER['SERVER_NAME'])
            ->flagStatus('httpOnly', true)
            ->flagStatus('ssl', true);

        if (true === $configuration->autoinit) {
            $this
                ->init($configuration)
                ->start();
        }
    }
1205404
public function do_destroy($session_id)
    {
        /** @var \ManaPHP\DbInterface $db */
        $db = $this->_di->getShared($this->_db);

        $db->delete($this->_source, ['session_id' => $session_id]);

        return true;
    }
406801
public synchronized USER remove(final ID sessionId)
	{
		final USER user = getUser(sessionId);
		if (user != null)
		{
			usersOnline.remove(user);
		}
		sessionIdToUser.remove(sessionId);
		return user;
	}
780233
function get_session_by_id($sessionid) {
        try {
            $param = new \Panopto\SessionManagement\GetSessionsById($this->auth, array($sessionid));
            $sessions = $this->smclient->GetSessionsById($param)->getGetSessionsByIdResult()->getSession();
        } catch (Exception $e) {
            return false;
        }
        if (count($sessions)) {
            return $sessions[0];
        }
        return false;
    }
729368
protected function doRead($sessionId)
    {
        $item = $this->getCacheItem($sessionId);

        if ($item->isHit()) {
            return $item->get();
        }

        return '';
    }
141695
public function setSessionId($sessionId)
    {
        $this->set(self::MAUTIC_SESSION_ID, $sessionId);
        $this->set(self::MTC_SID, $sessionId);

        return $this;
    }
1323498
public static function popSessionCookie(string $sessionName, string $sessionId): ?string
    {
        $sessionCookie = null;
        $sessionCookiePrefix = sprintf(' %s=', urlencode($sessionName));
        $sessionCookieWithId = sprintf('%s%s;', $sessionCookiePrefix, urlencode($sessionId));
        $otherCookies = [];
        foreach (headers_list() as $h) {
            if (0 !== stripos($h, 'Set-Cookie:')) {
                continue;
            }
            if (11 === strpos($h, $sessionCookiePrefix, 11)) {
                $sessionCookie = $h;

                if (11 !== strpos($h, $sessionCookieWithId, 11)) {
                    $otherCookies[] = $h;
                }
            } else {
                $otherCookies[] = $h;
            }
        }
        if (null === $sessionCookie) {
            return null;
        }

        header_remove('Set-Cookie');
        foreach ($otherCookies as $h) {
            header($h, false);
        }

        return $sessionCookie;
    }
1298488
public function destroySession(SsoClient $ssoClient, $sessionId) {
		$serviceUri = new Uri($this->serviceBaseUri . '/session/' . urlencode($sessionId) . '/destroy');
		$serviceUri->setQuery(http_build_query(array('clientIdentifier' => $ssoClient->getServiceBaseUri())));
		$request = \TYPO3\Flow\Http\Request::create($serviceUri, 'DELETE');
		$request->setContent('');

		$signedRequest = $this->requestSigner->signRequest($request, $ssoClient->getPublicKeyFingerprint(), $ssoClient->getPublicKeyFingerprint());

		// TODO Send request asynchronously
		$response = $this->requestEngine->sendRequest($signedRequest);
		if ($response->getStatusCode() !== 200 && $response->getStatusCode() !== 404) {
			throw new Exception('Unexpected status code for destroy session when calling "' . (string)$serviceUri . '": "' . $response->getStatus() . '"', 1354132939);
		}
	}
583684
public function start(string $sessionID = null)
    {
        if($this->isStart)
        {
            throw new \RuntimeException('Session can not repeated start');
        }
        $this->handler = RequestContext::getServerBean($this->handlerClass);
        $this->isNewSession = null === $sessionID;
        if($this->isNewSession)
        {
            $this->id = $this->handler->createSessionID();
        }
        else
        {
            $this->id = $sessionID;
            $this->data = $this->handler->decode($this->handler->read($this->id));
        }
        $this->isStart = true;
    }
450156
public function startSession($sessionId = NULl){
        if($sessionId != NULL){ 
            session_id($sessionId);
        }
        session_start();
        $this->checkIdentity();
    }
570440
public function read($sessionId): string
    {
        $encryptedData = parent::read($sessionId);

        return $this->decrypt($encryptedData);
    }
1332733
public function destroy($session_id = null)
    {
        if ($session_id) {
            $this->eventsManager->fireEvent('session:destroy', $this, ['session_id' => $session_id]);
            $this->do_destroy($session_id);
        } else {

            $context = $this->_context;

            if (!$context->started) {
                $this->_start();
            }

            $this->eventsManager->fireEvent('session:destroy', $this, ['session_id' => $session_id, 'context' => $context]);

            $context->started = false;
            $context->is_dirty = false;
            $context->session_id = null;
            $context->_SESSION = null;
            $this->do_destroy($context->session_id);

            $params = $this->_cookie_params;
            $this->cookies->delete($this->_name, $params['path'], $params['domain'], $params['secure'], $params['httponly']);
        }
    }
330571
protected function setSessionId($sessionId) {
    $session = ObjectFactory::getInstance('session');
    $sids = $session->get(self::SIDS_SESSION_VARNAME);
    $sids[$this->serverCli] = $sessionId;
    $session->set(self::SIDS_SESSION_VARNAME, $sids);
  }
219172
public function buildDestroySessionRequest(SsoServer $ssoServer, $sessionId) {
		$serviceUri = new Uri(rtrim($this->serviceBaseUri, '/') . '/session/' . urlencode($sessionId) . '/destroy');
		$serviceUri->setQuery(http_build_query(array('serverIdentifier' => $ssoServer->getServiceBaseUri())));
		$request = \TYPO3\Flow\Http\Request::create($serviceUri, 'DELETE');
		$request->setContent('');

		return $this->requestSigner->signRequest($request, $ssoServer->getKeyPairFingerprint(), $ssoServer->getKeyPairFingerprint());
	}