Hash.py 文件源码

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

项目:Python-IRC-Bot 作者: wolfy1339 项目源码 文件源码
def hash_cmd(bot, event, irc, args):
    """<hashing mechanism> <string to hash>
    Returns a hexadecimal digest of the hashed provided string"""
    if args[0] in hashlib.algorithms_available:
        func = getattr(hashlib, args[0])
        irc.reply(event, func(" ".join(args[1:]).encode()).hexdigest())
    else:
        irc.reply(event, "Unknown hashing mechanism: " + args[0])
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号