module Hook::Echo
Defined in:
hook-echo.crConstant Summary
- 
        MAX_PAYLOAD = 2 ** 20
- 
        you should probably always put an upperbound on how much data your application is willing to read into memory 
- 
        SIGNATURE_HEADER = "X-FP-Webhook-Signature-Hmac-Sha-256"
- 
        this is the header that stores the signature flowplayer generates to verify that it hasn't been tampered with in the middle 
- 
        SIGNING_SECRET = ENV["FLOWPLAYER_WEBHOOK_SECRET"]
- 
        fetch the signing secret from environment variables 
- 
        VERSION = "0.1.0"
Class Method Summary
- .accept(context)
- 
        .extract_body(context)
        
          read the request payload (max 1mb) into memory 
- 
        .no_unicorns(context)
        
          generic 404 message 
- 
        .route(context)
        
          simple router that matches: 1. 
- .run
- 
        .signature_mismatch(context)
        
          specific 403 message when the payload signatures do not match 
- 
        .verified?(sig, payload)
        
          verify the remote signature with our locally calculated signature 
Class Method Detail
        
        def self.signature_mismatch(context)
        #
      
      
        specific 403 message when the payload signatures do not match
        
        def self.verified?(sig, payload)
        #
      
      
        verify the remote signature with our locally calculated signature