Packages

o

pdi.jwt

JwtArrayUtils

object JwtArrayUtils

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. JwtArrayUtils
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Value Members

  1. def constantTimeAreEqual(expected: Array[Byte], supplied: Array[Byte]): Boolean

    A constant time equals comparison - does not terminate early if test will fail.

    A constant time equals comparison - does not terminate early if test will fail. For best results always pass the expected value as the first parameter.

    Ported from BouncyCastle to remove the need for a runtime dependency. https://github.com/bcgit/bc-java/blob/290df7b4edfc77b32d55d0a329bf15ef5b98733b/core/src/main/java/org/bouncycastle/util/Arrays.java#L136-L172

    expected

    first array

    supplied

    second array

    returns

    true if arrays equal, false otherwise.