BinaryField

Extends\phpseclib3\Math\Common\FiniteField

Binary Finite Fields

author

Jim Wigginton terrafrost@php.net

package

Default

Methods

Default constructor

__construct( $indices)

Arguments

$indices

Converts a base-256 string to a base-2 string

base256ToBase2(string $x): string
static

Arguments

$x

string

Response

string

Converts a base-2 string to a base-256 string

base2ToBase256(string $x,integer|null $size = null): string
static

Arguments

$x

string

$size

integer|null

Response

string

Returns the length of the modulo in bits

getLength(): integer

Response

integer

Returns the length of the modulo in bytes

getLengthInBytes(): integer

Response

integer

Returns an instance of a dynamically generated PrimeFieldInteger class

newInteger(string $num): Integer

Arguments

$num

string

Response

Integer

Returns an integer on the finite field between one and the prime modulo

randomInteger(): Integer

Response

Integer

Properties

Instance Counter

instanceCounter :integer
static
var

Type(s)

integer

Keeps track of current instance

instanceID :integer
var

Type(s)

integer

randomMax

randomMax :\phpseclib3\Math\BigInteger