abstract class Sodium::Cipher::Chalsa
  
  - Sodium::Cipher::Chalsa
 - Reference
 - Object
 
Overview
The great beat you can eat!
What? They're both dance?
Included Modules
- Random
 
Direct Known Subclasses
- Sodium::Cipher::ChaCha20
 - Sodium::Cipher::ChaCha20Ietf
 - Sodium::Cipher::Salsa20
 - Sodium::Cipher::XChaCha20
 - Sodium::Cipher::XSalsa20
 
Defined in:
sodium/cipher/chalsa.crConstructors
Instance Method Summary
- 
        #dup
        
          
Returns a shallow copy of this object.
 - 
        #edible?
        
          
Always returns false.
 - 
        #final
        
          
Provided for compatibility with block or tagged ciphers.
 - #key : Crypto::Secret
 - 
        #key=(key : Bytes | Crypto::Secret) : Crypto::Secret
        
          
DEPRECATED Use constructor to set key
 - #key_size : Int32
 - 
        #next_u : UInt8
        
          
Generates a random unsigned integer.
 - #nonce : Bytes | Nil
 - #nonce=(nonce : Bytes)
 - #nonce? : Bytes | Nil | Nil
 - #nonce_size : Int32
 - 
        #offset : UInt64
        
          
Advanced usage.
 - 
        #offset=(offset : UInt64)
        
          
Advanced usage.
 - 
        #random_bytes(bytes : Bytes) : Bytes
        
          
Use as a CSPRNG.
 - 
        #random_key
        
          
DEPRECATED Use constructor to set key
 - #random_nonce
 - #update(src : Bytes, dst : Bytes)
 - 
        #update(src : Bytes) : Bytes
        
          
Xor's src with the cipher output and returns a new Slice
 
Constructor Detail
Instance Method Detail
        
        def dup
        #
      
      
        
              Description copied from class Reference
            
          
          Returns a shallow copy of this object.
This allocates a new object and copies the contents of
self into it.
        
        def final
        #
      
      
        Provided for compatibility with block or tagged ciphers. Stream ciphers don't have additional data.
        
        def next_u : UInt8
        #
      
      
        
              Description copied from module Random
            
          
          Generates a random unsigned integer.
The integers must be uniformly distributed between 0 and
the maximal value for the chosen type.