Base32Hex

Extends\ParagonIE\ConstantTime\Base32

Class Base32Hex [0-9][A-V]

package

ParagonIE\ConstantTime

Methods

Decode a Base32-encoded string into raw binary

decode(string $encodedString,boolean $strictPadding = false): string
inheritedstatic

Arguments

$encodedString

string

$strictPadding

boolean

Error on invalid padding

Response

string

Uses bitwise operators instead of table-lookups to turn 5-bit integers into 8-bit integers.

decode5Bits(integer $src): integer
inheritedstatic

Arguments

$src

integer

Response

integer

Uses bitwise operators instead of table-lookups to turn 5-bit integers into 8-bit integers.

decode5BitsUpper(integer $src): integer
inheritedstatic

Uppercase variant.

Arguments

$src

integer

Response

integer

decodeNoPadding

decodeNoPadding(string $encodedString,boolean $upper = false): string
inheritedstatic

Arguments

$encodedString

string

$upper

boolean

Response

string

Decode an uppercase Base32-encoded string into raw binary

decodeUpper(string $src,boolean $strictPadding = false): string
inheritedstatic

Arguments

$src

string

$strictPadding

boolean

Response

string

Base32 decoding

doDecode(string $src,boolean $upper = false,boolean $strictPadding = false): string
inheritedstatic
psalm-suppress

RedundantCondition

Throws
\TypeError

Arguments

$src

string

$upper

boolean

$strictPadding

boolean

Response

string

Base32 Encoding

doEncode(string $src,boolean $upper = false,boolean $pad = true): string
inheritedstatic
Throws
\TypeError

Arguments

$src

string

$upper

boolean

$pad

boolean

Response

string

Encode into Base32 (RFC 4648)

encode(string $binString): string
inheritedstatic
Throws
\TypeError

Arguments

$binString

string

(raw binary)

Response

string

Uses bitwise operators instead of table-lookups to turn 8-bit integers into 5-bit integers.

encode5Bits(integer $src): string
inheritedstatic

Arguments

$src

integer

Response

string

Uses bitwise operators instead of table-lookups to turn 8-bit integers into 5-bit integers.

encode5BitsUpper(integer $src): string
inheritedstatic

Uppercase variant.

Arguments

$src

integer

Response

string

Encode into Base32 (RFC 4648)

encodeUnpadded(string $src): string
inheritedstatic
Throws
\TypeError

Arguments

$src

string

Response

string

Encode into uppercase Base32 (RFC 4648)

encodeUpper(string $src): string
inheritedstatic
Throws
\TypeError

Arguments

$src

string

Response

string

Encode into uppercase Base32 (RFC 4648)

encodeUpperUnpadded(string $src): string
inheritedstatic
Throws
\TypeError

Arguments

$src

string

Response

string