What is $_SESSION and how do i secure SESSION name in PHP
<p>my SESSION starts after sucessesfull login and i really don't know how safe is my SESSION value </p>

<p>My SESSION value is <code>user name</code> and here is my code</p>

<pre><code>&lt;?php
require_once('includes/config.php');
if ($user-&gt;is_logged_in()) {
    header('Location: signup.php');
}
if (isset($_POST['submit'])) {
    $username = filter_input(INPUT_POST, 'username');
    $password = filter_input(INPUT_POST, 'password');
    if ($user-&gt;login($username, $password)) {
        $_SESSION['username'] = $username;
        header('Location: index.php');
        exit;
    } else {
        $error[] = 'Wrong username or password or your account has not been activated.';
    }
}
?&gt;
</code></pre>

<p>Here is my function</p>

<pre><code>private function get_user_hash($username){  
        try {
            $stmt = $this-&gt;_db-&gt;prepare('SELECT password FROM members WHERE username = :username AND active="Yes" ');
            $stmt-&gt;execute(array('username' =&gt; $username));
            $row = $stmt-&gt;fetch();
            return $row['password'];
        } catch(PDOException $e) {
            echo '&lt;p class="bg-danger"&gt;'.$e-&gt;getMessage().'&lt;/p&gt;';
        }
    }
    public function login($username,$password){
        $hashed = $this-&gt;get_user_hash($username);
        if($this-&gt;password_verify($password,$hashed) == 1){
            $_SESSION['loggedin'] = true;
            return true;
        }   
    }
</code></pre>

<p>Now i need to know how safe is my <code>$_SESSION</code> </p>

<p>and how do i secure my $_SESSION value</p>