OpenPGP_S2K::sized_hash PHP Method

sized_hash() public method

public sized_hash ( $s, $size )
    function sized_hash($s, $size)
    {
        $hash = $this->raw_hash($s);
        while (strlen($hash) < $size) {
            $s = "" . $s;
            $hash .= $this->raw_hash($s);
        }
        return substr($hash, 0, $size);
    }