Read all data from farther down the stack (i.e. earlier-added handlers)
and then decrypt the data given specified keys.

@param string   $id   ID of the session to read
@param callable $next Callable to invoke the next layer in the stack

@return string
513885
public function read($id, $next)
    {
        $encrypted = $next( $id );

        return empty( $encrypted ) ? $encrypted : $this->decrypt( $next( $id ) );
    }
173052
public function read( $id ) {

		$id = $this->getKey( $id );

		// If possible use the raw data from the internal cache
		// without unserialization
		if ( $this->internalCache->contains( $id ) ) {
			$data = $this->internalCache->fetch( $id );
		} elseif ( $this->cache->contains( $id ) ) {
			$data = unserialize( $this->cache->fetch( $id ) );
			$this->internalCache->save( $id, $data );
		} else {
			$data = array();
		}

		$container = new Container( $id, (array)$data );
		$container->setExpiryInSeconds( $this->expiry );

		return $container;
	}
232470
function encryptInit($id)
    {
        $tmp = $this->encryptionKey;
        $hex = dechex($id);
        if (mb_strlen($hex, '8bit') < 6) {
            $hex = substr('000000', 0, 6 - mb_strlen($hex, '8bit')) . $hex;
        }
        $tmp .= chr(hexdec(substr($hex, 4, 2)))
            . chr(hexdec(substr($hex, 2, 2)))
            . chr(hexdec(substr($hex, 0, 2)))
            . chr(0)
            . chr(0)
        ;
        $key = $this->md5_16($tmp);
        $this->ARC4_init(substr($key, 0, 10));
    }
551653
public function read(int $id, int &$offset = 0, bool $cleanup = true)
    {
        $this->logger->beginProfile('read_' . $id);
        $key    = $this->getSharedItemKey($id);
        $sh     = shmop_open($key, 'a', 0, 0);
        $header = shmop_read($sh, 0, self::HEADER_SIZE);
        list($id, $off, $size, $flags) = $this->unpackHeader($header);
        $this->logger->debug(sprintf('Reading state: (key = 0x%08x, shmid = %d)', $key, $sh));
        $this->logger->debug(sprintf("State header: (id = %d, offset = %d, size = 0x%08x, flags = 0x%03x)", $id,
            $offset,
            $size, $flags));

        $result = shmop_read($sh, self::HEADER_SIZE, $size);
        $this->logger->debug(sprintf('State data: (size = 0x%08x)', mb_strlen($result, 'utf-8')));
        if ($cleanup) {
            shmop_delete($sh);
        }

        shmop_close($sh);

        $result = $this->getResult($result, $flags);
        $offset = $off;

        $this->logger->endProfile('read_' . $id, "Reading {$id} data");

        return $result;
    }
1247523
public function read($id) {
        $tmp      = $_SESSION;
        $key      = $this->getKey($id);
        $_SESSION = json_decode($this->mem->get($key, false, ''), true);


        // TODO: replace all of this with custom session data modifiers to be executed one by one
        // TODO: Create CachedSessionHandler that accepts AbstractStorage as its storage
        // TODO: Refactor this to extend CachedSessionHandler and use JSON encode/decode where needed
        $user = $this->getUser();

        if ($user instanceof UserInterface) {
            $roles = array();
            /** @var RoleInterface $role */
            foreach ($user->getRoles() as $role) {
                $roles[] = $role->getRole();
            }
            $userData         = array(
                'username' => $user->getUsername(),
                'roles'    => $roles
            );
            $_SESSION['user'] = $userData;
        }

        if (isset($_SESSION) && !empty($_SESSION) && $_SESSION != null) {
            $new_data = session_encode();
            $_SESSION = $tmp;
            return $new_data;
        }
        return '';
    }
131978
public function read($id)
    {
        if (!$data = $this->getCache()->load($this->normalizeId($id))) {
            return null;
        }

        return $data;
    }
436324
public function load($id)
    {

        try {
            // prepare the pathname to the file containing the session data
            $filename = $this->getSessionSettings()->getSessionFilePrefix() . $id;
            $pathname = $this->getSessionSavePath($filename);

            // unpersist and return the session from the file system
            return $this->unpersist($pathname);

        } catch (SessionDataNotReadableException $sdnre) {
            $this->delete($id);
            throw $sdnre;
        }
    }
346707
protected function getRowKey($id)
    {
        foreach ($this->getData() as $key => $data)
        {
            if ($data->{$this->databaseConfig->getIdentifier()} == $id)
            {
                return $key;
                break;
            }
        }
        throw new \Exception('No data found with ID: ' . $id);
    }
404083
public function read($id)
    {
        // Check if id exists
        if (!xcache_isset($this->prefix . $id)) {
            return false;
        }

        return (string) xcache_get($this->prefix . $id);
    }
127209
public function getNodeById($id, $recursively = false) {
        $found = null;
        if (true === array_key_exists($id, $this->index)) {
            $found = $this->getNodeAt($this->index[$id]);
        }
        if (null === $found && true === $recursively) {
            foreach ($this->nodes as $current) {
                $found = $current->getNodeById($id, $recursively);
                if (null !== $found) {
                    break;
                }
            }
        }
        return $found;
    }
253385
public function readSession($id)
    {
        $data = $this->ssdbHandle->get($this->calculateKey($id));
        return $data === false ? '' : $data;
    }
491601
public function loadPathData($id)
    {
        try {
            return $this->innerGateway->loadPathData($id);
        } catch (DBALException $e) {
            throw new \RuntimeException('Database error', 0, $e);
        } catch (PDOException $e) {
            throw new \RuntimeException('Database error', 0, $e);
        }
    }
788689
public function readSession($id)
    {
        $data = $this->cache->get($this->calculateKey($id));

        return $data === null ? '' : $data;
    }
1144126
public static function getIdValue(array $id) 
    {
        self::formatScalarValues($id);
        if (\is_array($id)) {
            RecursiveDeleteHelper::deleteKeys($id, [Serializer::CLASS_IDENTIFIER_KEY]);
        }

        return $id;
    }
629309
public function read($id)
    {
        $session = $this->entityManager->find($this->entityManager, $id);
        if (null !== $session) {
            if ($this->_getExpirationTime($session) > time()) {
                return $session->{$this->dataColumn};
            } else {
                $this->destroy($id);
            }
        }

        return '';
    }
1126946
function read($id) {
		if ($id!=$this->sid)
			$this->sid=$id;
		return Cache::instance()->exists($id.'.@',$data)?$data['data']:FALSE;
	}
805995
public function read($id)
	{
		$tableName = $this->db->parseField($this->tableName);
		$sessionID = $this->db->parseField('session_id');
		$result = $this->db->query(<<<SQL
select * from {$tableName} where {$sessionID} = %s
SQL
,array($id));
		if(isset($result['data']))
		{
			return $result['data'];
		}
		else
		{
			return '';
		}
	}