A wrapper class to access fido2 library APIs to interact with the device.  
 More...
#include <fido_assertion.h>
A wrapper class to access fido2 library APIs to interact with the device. 
This class abstracts all access to FIDO device. 
 
◆ fido_prepare_assert()
      
        
          | fido_prepare_assert::fido_prepare_assert  | 
          ( | 
           | ) | 
           | 
        
      
 
Construcutor to allocate memory for performing assertion (authentication) 
 
 
◆ ~fido_prepare_assert()
      
        
          | fido_prepare_assert::~fido_prepare_assert  | 
          ( | 
           | ) | 
           | 
        
      
 
 
◆ get_authdata_len()
  
  
      
        
          | size_t fido_prepare_assert::get_authdata_len  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
private   | 
  
 
Method to get length of authenticator data. 
- Return values
 - 
  
    | length | of authenticator data  | 
  
   
 
 
◆ get_authdata_ptr()
  
  
      
        
          | const unsigned char * fido_prepare_assert::get_authdata_ptr  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
private   | 
  
 
Method to get authenticator data. 
- Return values
 - 
  
    | buffer | holding authenticator data  | 
  
   
 
 
◆ get_signature_len()
  
  
      
        
          | size_t fido_prepare_assert::get_signature_len  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
private   | 
  
 
Method to get length of signature. 
- Return values
 - 
  
  
 
 
 
◆ get_signature_ptr()
  
  
      
        
          | const unsigned char * fido_prepare_assert::get_signature_ptr  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
private   | 
  
 
Method to get signature. 
- Return values
 - 
  
    | buffer | holding signature data  | 
  
   
 
 
◆ get_signed_challenge()
      
        
          | void fido_prepare_assert::get_signed_challenge  | 
          ( | 
          unsigned char **  | 
          challenge_res,  | 
        
        
           | 
           | 
          size_t &  | 
          challenge_res_len  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
This method will extract authenticator data, signature from fido_assert_t struct. 
- Parameters
 - 
  
    | [out] | challenge_res | buffer to signed challenge  | 
    | [out] | challenge_res_len | length of signed challenge  | 
  
   
 
 
◆ parse_challenge()
      
        
          | bool fido_prepare_assert::parse_challenge  | 
          ( | 
          const unsigned char *  | 
          challenge | ) | 
           | 
        
      
 
Helper method to parse the challenge received from server during authentication process. 
This method extracts salt, relying party name and set it in fido_assert_t.
- Parameters
 - 
  
    | [in] | challenge | buffer holding the server challenge | 
  
   
- Return values
 - 
  
    | false | received challenge was valid  | 
    | true | received challenge was corrupt  | 
  
   
 
 
◆ set_cred_id()
  
  
      
        
          | void fido_prepare_assert::set_cred_id  | 
          ( | 
          unsigned char *  | 
          cred,  | 
         
        
           | 
           | 
          size_t  | 
          len  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
private   | 
  
 
Set method to set credential ID. 
- Parameters
 - 
  
    | [in] | cred | buffer holding credential ID  | 
    | [in] | len | length of credential ID  | 
  
   
 
 
◆ set_rp_id()
  
  
      
        
          | void fido_prepare_assert::set_rp_id  | 
          ( | 
          const char *  | 
          rp_id | ) | 
           | 
         
       
   | 
  
private   | 
  
 
Method to set the relying party name or id. 
- Parameters
 - 
  
    | [in] | rp_id | buffer holding relying party name  | 
  
   
 
 
◆ set_scramble()
  
  
      
        
          | void fido_prepare_assert::set_scramble  | 
          ( | 
          unsigned char *  | 
          scramble,  | 
         
        
           | 
           | 
          size_t  | 
          len  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
private   | 
  
 
Set method to set 32 bit random salt. 
- Parameters
 - 
  
    | [in] | scramble | buffer holding random salt  | 
    | [in] | len | length of salt  | 
  
   
 
 
◆ sign_challenge()
      
        
          | bool fido_prepare_assert::sign_challenge  | 
          ( | 
           | ) | 
           | 
        
      
 
Method to obtains an assertion from a FIDO device. 
- Return values
 - 
  
    | false | assertion successful.  | 
    | true | assertion failed.  | 
  
   
 
 
◆ m_assert
  
  
      
        
          | fido_assert_t* fido_prepare_assert::m_assert | 
         
       
   | 
  
private   | 
  
 
 
The documentation for this class was generated from the following files: