IT. Expert System.

Android Reference

SHA1PRNG_SecureRandomImpl


org.apache.harmony.security.provider.crypto

Class SHA1PRNG_SecureRandomImpl

  • All Implemented Interfaces:
    Serializable, SHA1_Data


    public class SHA1PRNG_SecureRandomImpl
    extends SecureRandomSpi
    implements Serializable, SHA1_Data
    This class extends the SecureRandomSpi class implementing all its abstract methods.

    To generate pseudo-random bits, the implementation uses technique described in the "Random Number Generator (RNG) algorithms" section, Appendix A, JavaTM Cryptography Architecture, API Specification&Reference

    The class implements the Serializable interface.
    See Also:
    Serialized Form
    • Constructor Detail

      • SHA1PRNG_SecureRandomImpl

        public SHA1PRNG_SecureRandomImpl()
        Creates object and sets implementation variables to their initial values
    • Method Detail

      • engineSetSeed

        protected void engineSetSeed(byte[] seed)
        Changes current seed by supplementing a seed argument to the current seed, if this already set; the argument is used as first seed otherwise.
        The method overrides "engineSetSeed(byte[])" in class SecureRandomSpi.
        Specified by:
        engineSetSeed in class SecureRandomSpi
        Parameters:
        seed - - byte array
        Throws:
        NullPointerException - - if null is passed to the "seed" argument
      • engineGenerateSeed

        protected byte[] engineGenerateSeed(int numBytes)
        Returns a required number of random bytes.
        The method overrides "engineGenerateSeed (int)" in class SecureRandomSpi.
        Specified by:
        engineGenerateSeed in class SecureRandomSpi
        Parameters:
        numBytes - - number of bytes to return; should be >= 0.
        Returns:
        byte array containing bits in order from left to right
        Throws:
        InvalidParameterException - - if numBytes < 0
      • engineNextBytes

        protected void engineNextBytes(byte[] bytes)
        Writes random bytes into an array supplied. Bits in a byte are from left to right.
        To generate random bytes, the "expansion of source bits" method is used, that is, the current seed with a 64-bit counter appended is used to compute new bits. The counter is incremented by 1 for each 20-byte output.
        The method overrides engineNextBytes in class SecureRandomSpi.
        Specified by:
        engineNextBytes in class SecureRandomSpi
        Parameters:
        bytes - - byte array to be filled in with bytes
        Throws:
        NullPointerException - - if null is passed to the "bytes" argument


Content

Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)

SQL

HTML

PHP

CSS

Java Script

MYSQL

JQUERY

VBS

REGEX

C

C++

C#

Design patterns

RFC (standard status)

RFC (proposed standard status)

RFC (draft standard status)

RFC (informational status)

RFC (experimental status)

RFC (best current practice status)

RFC (historic status)

RFC (unknown status)

IT dictionary

License.
All information of this service is derived from the free sources and is provided solely in the form of quotations. This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 126 / 158777649. Delta: 0.03111 с