Package tlslite :: Module dh
[hide private]
[frames] | no frames]

Module dh

source code

Handling of Diffie-Hellman parameter files.

Functions [hide private]
tuple of int
parse(data)
Parses DH parameters from a binary string.
source code
tuple of int
parseBinary(data)
Parse DH parameters from ASN.1 DER encoded binary string.
source code
Variables [hide private]
  __package__ = 'tlslite'
Function Details [hide private]

parse(data)

source code 

Parses DH parameters from a binary string.

The string can either by PEM or DER encoded

Parameters:
  • data - DH parameters
Returns: tuple of int
generator and prime

parseBinary(data)

source code 

Parse DH parameters from ASN.1 DER encoded binary string.

Parameters:
  • data - DH parameters
Returns: tuple of int