Component for creating signed URLs.  
 More...
Component for creating signed URLs. 
@access private 
Definition at line 10 of file UrlSigner.php.
◆ isValid()
      
        
          | Elgg\Security\UrlSigner::isValid | ( |  | $url | ) |  | 
      
 
Validates HMAC signature. 
- Parameters
- 
  
    | string | $url | URL to vlaidate |  
 
- Returns
- bool 
Definition at line 65 of file UrlSigner.php.
 
 
◆ sign()
      
        
          | Elgg\Security\UrlSigner::sign | ( |  | $url, | 
        
          |  |  |  | $expires = false | 
        
          |  | ) |  |  | 
      
 
Normalizes and signs the URL with SHA256 HMAC key. 
- Note
- Signed URLs do not offer CSRF protection and should not be used instead of action tokens.
- Parameters
- 
  
    | string | $url | URL to sign |  | string | $expires | Expiration time Accepts a string suitable for strtotime() Falsey values indicate non-expiring URL |  
 
- Returns
- string 
- Exceptions
- 
  
  
Definition at line 27 of file UrlSigner.php.
 
 
◆ KEY_EXPIRES
      
        
          | const Elgg\Security\UrlSigner::KEY_EXPIRES = '__elgg_exp' | 
      
 
 
◆ KEY_MAC
      
        
          | const Elgg\Security\UrlSigner::KEY_MAC = '__elgg_mac' | 
      
 
 
The documentation for this class was generated from the following file: