commands.py 文件源码

python
阅读 27 收藏 0 点赞 0 评论 0

项目:lbryum 作者: lbryio 项目源码 文件源码
def _validate_signed_claim(claim, claim_address, certificate):
        if not claim.has_signature:
            raise Exception("Claim is not signed")
        if not base_decode(claim_address, ADDRESS_LENGTH, 58):
            raise Exception("Not given a valid claim address")
        try:
            if claim.validate_signature(claim_address, certificate.protobuf):
                return True
        except BadSignatureError:
            # print_msg("Signature for %s is invalid" % claim_id)
            return False
        except Exception as err:
            log.error("Signature for %s is invalid, reason: %s - %s", claim_address,
                      str(type(err)), err)
            return False
        return False
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号