'Returns the PermID of the Session, as determined by the
TriblerConfig.set_permid() parameter. A PermID is a public key.
:return: the PermID encoded in a string in DER format'

def get_permid(self):

    return str(self.keypair.pub().get_der())
