Overview | Package | Class | Tree | Deprecated | Index | Help
| For the latest news and information visit The GNU Crypto project
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## gnu.crypto.prng
Class MDGenerator

    java.lang.Object
      |
      +--gnu.crypto.prng.BasePRNG
            |
            +--gnu.crypto.prng.MDGenerator

All Implemented Interfaces:
  java.lang.Cloneable, IRandom

public class MDGenerator
extends BasePRNG

A simple pseudo-random number generator that relies on a hash algorithm, that (a) starts its operation by hashing a `seed`, and then (b) continuously re-hashing its output. If no hash algorithm name is specified in the `Map` of attributes used to initialise the instance then the SHA-160 algorithm is used as the underlying hash function. Also, if no `seed` is given, an empty octet sequence is used.

Version:
  $Revision: 1.6 $

Field Summary
`static java.lang.String` | `MD_NAME` Property name of underlying hash algorithm for this generator.
`static java.lang.String` | `SEEED` Property name of seed material.

Fields inherited from class gnu.crypto.prng.BasePRNG
`buffer, initialised, name, ndx`

Constructor Summary
`MDGenerator()` Trivial 0-arguments constructor.

Method Summary
`java.lang.Object` | `clone()` Returns a clone copy of this instance.
`void` | `fillBlock()`
`void` | `setup(java.util.Map attributes)`

Methods inherited from class gnu.crypto.prng.BasePRNG
`init, isInitialised, name, nextByte, nextBytes`

Methods inherited from class java.lang.Object
`, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### MD_NAME

    public static final java.lang.String MD_NAME

  Property name of underlying hash algorithm for this generator.

### SEEED

    public static final java.lang.String SEEED

  Property name of seed material.

Constructor Detail

### MDGenerator

    public MDGenerator()

  Trivial 0-arguments constructor.

Method Detail

### clone

    public java.lang.Object clone()

  Description copied from interface: `IRandom`

  Returns a clone copy of this instance.

  Overrides:
    `clone` in class `BasePRNG`
  Following copied from interface: `gnu.crypto.prng.IRandom`
  Returns:
    a clone copy of this instance.

### setup

    public void setup(java.util.Map attributes)

  Overrides:
    `setup` in class `BasePRNG`

### fillBlock

    public void fillBlock()
                   throws LimitReachedException

  Overrides:
    `fillBlock` in class `BasePRNG`

Overview | Package | Class | Tree | Deprecated | Index | Help
| For the latest news and information visit The GNU Crypto project
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright ©2001-2002 Free Software Foundation, Inc.. All Rights Reserved.