crypto.py 文件源码

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

项目:mflod 作者: arachnid42 项目源码 文件源码
def __get_asn1_algorithm_identifier(self, oid_str):
        """ Generate ASN.1 structure for algorithm identifier

        @developer: vsmysle

        :param oid_str: string OID to encapsulate

        :return: pyasn1.type.univ.Sequence object

        """

        # TODO: add exceptions

        # log entry
        self.logger.debug("creating AlgorithmIdentifier ASN.1 "
                          "structure with OID=%s" % oid_str)

        # create the instance of AlgorithmIdentifier
        ai = asn1_dec.AlgorithmIdentifier()

        # set corresponding parameters
        ai['algorithm'] = oid_str
        ai['parameters'] = univ.Null()

        # return the result
        return ai
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号