BinHandle Type
Represents the main data structure for accessing a chunk of binary code. It provides ways to read raw data from the binary through addresses and to access binary file metadata through the IBinFile interface. It also provides ways to parse/lift instructions from the binary through LiftingUnit.
Constructors
| Constructor | Description | 
            
                
              
              
             | 
          |
            
                
              
              
             | 
          |
            
                
              
              
             | 
          |
            
                
              
               | 
          |
            
                
              
              
             | 
          |
            
                
              
              
             | 
          
Instance members
| Instance member | Description | 
            
  | 
        |
            
                
              
              
             | 
          |
            
                
              
              
                  Full Usage: 
                   
              this.MakeNew
                  Parameters: 
 byte[]
                       - 
                      The byte array.
                    
                    Returns: BinHandle
                  
                  
 Return a new BinHandle.
 
                   | 
          |
            
                
              
               | 
          
            
  | 
        
            
                
              
              
                  Full Usage: 
                   
              this.ReadASCII
                  Parameters: 
 BinFilePointer
                       - 
                      BinFilePointer.
                    
                    Returns: string
                  
                  
 Return the corresponding ASCII string.
 
                   | 
          |
            
                
              
              
                  Full Usage: 
                   
              this.ReadASCII
                  Parameters: 
 Addr
                       - 
                      The address.
                    
                    Returns: string
                  
                  
 Return the corresponding ASCII string.
 
                   | 
          |
            
                
              
              
                  Full Usage: 
                   
              this.ReadBytes
                  Parameters: 
 Addr
                       - 
                      The address.
                    
                    nBytes : int
                       - 
                      The size of the byte array (in bytes).
                    
                    Returns: byte[]
                  
                  
 Return the byte array if succeed. Otherwise, raise an exception.
 
                   | 
          
            
 
  | 
        
            
                
              
              
                  Full Usage: 
                   
              this.ReadBytes
                  Parameters: 
 BinFilePointer
                       - 
                      BInaryPointer.
                    
                    nBytes : int
                       - 
                      The size of the byte array (in bytes).
                    
                    Returns: byte[]
                  
                  
 Return the byte array if succeed. Otherwise, raise an exception.
 
                   | 
          
            
 
  | 
        
            
                
              
              
                  Full Usage: 
                   
              this.ReadInt
                  Parameters: 
 Addr
                       - 
                      The address.
                    
                    size : int
                       - 
                      The size of the integer in bytes. Maximum 8 bytes is
 possible.
                    
                    Returns: int64
                  
                  
 Return the corresponding integer (int64).
 
                   | 
          
            
 
  | 
        
            
                
              
              
                  Full Usage: 
                   
              this.ReadInt
                  Parameters: 
 BinFilePointer
                       - 
                      The binary pointer.
                    
                    size : int
                       - 
                      The size of the integer in bytes. Maximum 8 bytes is
 possible.
                    
                    Returns: int64
                  
                  
 Return the corresponding integer (int64).
 
                   | 
          
            
 
  | 
        
            
                
              
              
                  Full Usage: 
                   
              this.ReadUInt
                  Parameters: 
 BinFilePointer
                       - 
                      BinFilePointer.
                    
                    size : int
                       - 
                      The size of the integer in bytes. Maximum 8 bytes is
 possible.
                    
                    Returns: uint64
                  
                  
 Return the corresponding unsigned integer (uint64).
 
                   | 
          
            
 
  | 
        
            
                
              
              
                  Full Usage: 
                   
              this.ReadUInt
                  Parameters: 
 Addr
                       - 
                      The address.
                    
                    size : int
                       - 
                      The size of the integer in bytes. Maximum 8 bytes is
 possible.
                    
                    Returns: uint64
                  
                  
 Return the corresponding unsigned integer (uint64).
 
                   | 
          
            
 
  | 
        
            
                
              
               | 
          
            
  | 
        
            
                
              
              
             | 
          |
            
                
              
              
                  Full Usage: 
                   
              this.TryReadBytes
                  Parameters: 
 BinFilePointer
                       - 
                      The binary pointer.
                    
                    nBytes : int
                       - 
                      The size of the byte array (in bytes).
                    
                    Returns: Result<byte[], ErrorCase>
                  
                  
 Return (byte[]) if succeeded, (ErrorCase) otherwise.
 
                   | 
          
            
  | 
        
            
                
              
              
                  Full Usage: 
                   
              this.TryReadInt
                  Parameters: 
 BinFilePointer
                       - 
                      BinFilePointer.
                    
                    size : int
                       - 
                      The size of the integer in bytes. Maximum 8 bytes is
 possible.
                    
                    Returns: Result<int64, ErrorCase>
                  
                  
 Return the corresponding value (int64) if the address and the size is
 valid. Otherwise ErrorCase.
 
                   | 
          
            
  | 
        
            
                
              
              
             | 
          |
            
                
              
              
                  Full Usage: 
                   
              this.TryReadUInt
                  Parameters: 
 BinFilePointer
                       - 
                      BinFilePointer.
                    
                    size : int
                       - 
                      The size of the integer in bytes. Maximum 8 bytes is
 possible.
                    
                    Returns: Result<uint64, ErrorCase>
                  
                  
 Return the corresponding unsigned integer (uint64) if the address and
 the size is valid. Otherwise, ErrorCase.
 
                   | 
          
            
  | 
        
            
                
              
              
             | 
          
            
  | 
        
            B2R2