Roboto

class Roboto @JvmOverloads constructor(val attestationConfiguration: AndroidAttestationConfiguration, verifyChallenge: (expected: ByteArray, actual: ByteArray) -> Boolean = { expected, actual -> expected contentEquals actual })(source)

Constructors

Link copied to clipboard
constructor(attestationConfiguration: AndroidAttestationConfiguration, verifyChallenge: (expected: ByteArray, actual: ByteArray) -> Boolean = { expected, actual -> expected contentEquals actual })

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
@JvmName(name = "collectDebugInfoSuspending")
suspend fun collectDebugInfo(certificates: List<X509Certificate>, expectedChallenge: ByteArray, verificationDate: Instant = Clock.System.now()): AndroidDebugAttestationStatement

Packs

Link copied to clipboard
fun Roboto.collectDebugInfoBlocking(certificates: List<X509Certificate>, expectedChallenge: ByteArray, verificationDate: Instant = Clock.System.now()): AndroidDebugAttestationStatement

Blocking version of Roboto.collectDebugInfo

Link copied to clipboard
@JvmName(name = "collectDebugInfo")
fun collectDebugInfoJ(certificates: List<X509Certificate>, expectedChallenge: ByteArray, verificationDate: Instant = java.time.Instant.now()): AndroidDebugAttestationStatement
@JvmName(name = "collectDebugInfo")
fun collectDebugInfoJ(certificates: List<X509Certificate>, expectedChallenge: ByteArray, verificationDate: Date = Date()): AndroidDebugAttestationStatement

Java-Friendly method

Link copied to clipboard
suspend fun verify(certificates: List<X509Certificate>, verificationDate: Instant = Clock.System.now(), expectedChallenge: ByteArray): KmmResult<List<X509Certificate>>

Verifies Android Key attestation Implements in accordance with https://developer.android.com/training/articles/security-key-attestation. Checks are performed according to the properties set in the attestationConfiguration.

Link copied to clipboard
@JvmName(name = "verifyAttestation")
fun verifyAttestation(certificates: List<X509Certificate>, verificationDate: Date = Date(), expectedChallenge: ByteArray): ParsedAttestationRecord

Java-Friendly method

Link copied to clipboard
fun Roboto.verifyBlocking(certificates: List<X509Certificate>, verificationDate: Instant = Clock.System.now(), expectedChallenge: ByteArray): KmmResult<List<X509Certificate>>

Blocking version of Roboto.verifyAttestation