| 1 | from typing import Callable, Union, Tuple, Optional |
| 2 | |
| 3 | __all__ = ['generate', 'construct', 'ElGamalKey'] |
| 4 | |
| 5 | RNG = Callable[[int], bytes] |
| 6 | |
| 7 | def generate(bits: int, randfunc: RNG) -> ElGamalKey: ... |
| 8 | def construct(tup: Union[Tuple[int, int, int], Tuple[int, int, int, int]]) -> ElGamalKey: ... |
| 9 | |
| 10 | class ElGamalKey(object): |
| 11 | def __init__(self, randfunc: Optional[RNG]=None) -> None: ... |
| 12 | def has_private(self) -> bool: ... |
| 13 | def can_encrypt(self) -> bool: ... |
| 14 | def can_sign(self) -> bool: ... |
| 15 | def publickey(self) -> ElGamalKey: ... |
| 16 | def __eq__(self, other: object) -> bool: ... |
| 17 | def __ne__(self, other: object) -> bool: ... |
| 18 | def __getstate__(self) -> None: ... |