Package 

Class ConfigValidator


  • 
    public class ConfigValidator
    
                        

    Detects if remote control feature is valid to run in Sandbox mode.

    • Method Detail

      • isConfigurationValid

        @NonNull() ValidationResult isConfigurationValid(@NonNull() RemoteConfiguration configuration, @Nullable() String cdnSig, @NonNull() String cdnToken, @NonNull() String devKey)

        validate the configuration received from CDN

        Parameters:
        configuration - received from CDN
        cdnSig - contains CDN signature
        cdnToken - used for CDN request
        devKey - for signing the hash
      • generateSignature

         String generateSignature(String key, String payload, String platform, String version, String token)

        Generate signature for remote control response. This signature should be equals tothe signature in the response headers.

        Parameters:
        key - to sign the HMAC SHA256
        payload - the full body of the remote-control CDN response
        platform - the platform the request is sent from
        version - Remote control API version
        token - used to fetch configuration