Ñò UVà[c @séddkZddkZddklZyddkZWnej o dZnXd„Zedj oei ƒi ƒdjpeidjo ddk l Z e i ƒZnddk lZei ƒZdefd „ƒYZdS( iÿÿÿÿN(t RandomPoolcCs<t|ƒt|ƒjpt‚ditd„||ƒƒS(NtcSstt|ƒt|ƒAƒS((tchrtord(txty((s0/usr/lib/python2.6/site-packages/paramiko/rng.pyts(tlentAssertionErrortjointmap(tatb((s0/usr/lib/python2.6/site-packages/paramiko/rng.pyt_strxors twindowstwin32(t rng_win32(t rng_posixtStrongLockingRandomPoolcBsGeZdZdd„Zdd„Zdd„Zdd„Zd„ZRS( s÷Wrapper around RandomPool guaranteeing strong random numbers. Crypto.Util.randpool.RandomPool will silently operate even if it is seeded with little or no entropy, and it provides no prediction resistance if its state is ever compromised throughout its runtime. It is also not thread-safe. This wrapper augments RandomPool by XORing its output with random bits from the operating system, and by controlling access to the underlying RandomPool using an exclusive lock. cCsh|djo tƒ}n||_tiƒ|_t|_|ii|ii dƒƒ|ii ƒdS(Ni ( tNonet _RandomPooltrandpoolt threadingtLockt randpool_lockt rng_devicetentropytstirtreadt randomize(tselftinstance((s0/usr/lib/python2.6/site-packages/paramiko/rng.pyt__init__Bs    RcCsC|iiƒz|ii|ƒWd|iiƒX|iiƒdS(N(RtacquireRRtreleaseRR(Rts((s0/usr/lib/python2.6/site-packages/paramiko/rng.pyRMs  icCsC|iiƒz|ii|ƒWd|iiƒX|iiƒdS(N(RR!RRR"R(RtN((s0/usr/lib/python2.6/site-packages/paramiko/rng.pyRUs  cCs6|iiƒz|ii|ƒWd|iiƒXdS(N(RR!Rt add_eventR"(RR#((s0/usr/lib/python2.6/site-packages/paramiko/rng.pyR%]s cCs™|iiƒz|ii|ƒ}Wd|iiƒX|ii|ƒ}t||ƒ}t|ƒ|jo&t|ƒ|jot|ƒ|jpt ‚|S(N( RR!Rt get_bytesR"RRR RR(RR$t randpool_datat entropy_datatresult((s0/usr/lib/python2.6/site-packages/paramiko/rng.pyR&ds @N( t__name__t __module__t__doc__RR RRR%R&(((s0/usr/lib/python2.6/site-packages/paramiko/rng.pyR6s     (tsysRtCrypto.Util.randpoolRRtplatformt ImportErrorRR tsystemtlowertparamikoRtopen_rng_deviceRRtobjectR(((s0/usr/lib/python2.6/site-packages/paramiko/rng.pyts    &