IntegrityManager

public interface IntegrityManager

com.google.android.play.core.integrity.IntegrityManager


Manages requests for integrity information.

Summary

Public methods

abstract Task<IntegrityTokenResponse> requestIntegrityToken(IntegrityTokenRequest request)

Generates and returns a token for integrity-related enquiries.

Public methods

requestIntegrityToken

public abstract Task<IntegrityTokenResponse> requestIntegrityToken (IntegrityTokenRequest request)

Generates and returns a token for integrity-related enquiries.

The JSON payload is signed and encrypted as a nested JWT, that is JWE of JWS.

JWE uses A256KW as a key wrapping algorithm and A256GCM as a content encryption algorithm. JWS uses ES256 as a signing algorithm.

All decryption and verification should be done within a secure server environment. Do not decrypt or verify the received token from within the client app. In particular, never expose any decryption keys to the client app.

See https://developer.android.com/google/play/integrity/verdict#token-format.

Parameters
request IntegrityTokenRequest: the object to request integrity token with.

Returns
Task<IntegrityTokenResponse> A Task that completes once the requestIntegrityToken flow succeeded or failed.