Alternating step generator
In cryptography, an alternating step generator (ASG) is a cryptographic pseudorandom number generator used in stream ciphers, based on three linear-feedback shift registers. Its output is a combination of two LFSRs which are stepped (clocked) in an alternating fashion, depending on the output of a third LFSR. The design was published in 1987 and patented in 1989 by C. G. Günther. Source: e01 Encyclopedia. Licence: CC BY-SA 4.0.
In cryptography, an alternating step generator (ASG) is a cryptographic pseudorandom number generator used in stream ciphers, based on three linear-feedback shift registers. Its output is a combination of two LFSRs which are stepped (clocked) in an alternating fashion, depending on the output of a third LFSR. The design was published in 1987 and patented in 1989 by C. G. Günther. /* 16-bit toy ASG (much too small for practical usage); return 0 or 1. */ unsigned ASG16toy(void) { static unsigned /* unsigned type with at least 16 bits */ lfsr2 = 0x8102, /* initial state, 16 bits, must not be 0 */ lfsr1 = 0x4210, /* initial state, 15 bits, must not be 0 */ lfsr0 = 0x2492; /* initial state, 14 bits, must not be 0 */ /* LFSR2 use x^^16 + x^^14 + x^^13 + x^^11 + 1 */ lfsr2 = (-(lfsr2&1))&0x8016 ^ lfsr2>>1; if (lfsr2&1) /* LFSR1 use x^^15 + x^^14 + 1 */ lfsr1 = (-(lfsr1&1))&0x4001 ^ lfsr1>>1; else /* LFSR0 use x^^14 + x^^13 + x^^3 + x^^2 + 1 */ lfsr0 = (-(lfsr0&1))&0x2C01 ^ lfsr0>>1; return (lfsr0 ^ lfsr1)&1; } An ASG is very simple to implement in hardware. In particular, contrary to the shrinking generator and self-shrinking generator, an output bit is produced at each clock, ensuring consistent performance and resistance to timing attacks.
Cite this
"Alternating step generator". 1698611857. e01 Encyclopedia. CC BY-SA 4.0. https://en.wikipedia.org/w/index.php?oldid=1182525698 JSON record · API collection · BibTeX · RIS · CSL-JSON · citation policy