国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 編程 > Python > 正文

壓縮包密碼破解示例分享(類似典破解)

2020-02-23 05:05:58
字體:
來源:轉載
供稿:網友

昨天翻硬盤,找到一個好東西,可惜自己加了密碼自己不記得了。試了幾個常用的沒試出來,于是寫了這么個小腳本來替我嘗試。。呵呵,還真給解出來了。
python腳本內容如下,跑跑自己加密的壓縮包還不錯

代碼如下:
# -*- coding: utf-8 -*-

import sys,os

def IsElementUniq(list):
    """
          判斷list中的元素是否為唯一的
    """
    for word in list:
        if list.count(word)>1:
            return False

    return True

def GenPswList():
    """
          要求用戶輸入詞,并根據單詞組合密碼,只嘗試四個單詞來組合,并限制密碼長度為20。寫的比較挫
    """
    psw=raw_input('input a word>')
    wordlist = []
    while psw:
        wordlist.append(psw)
        psw=raw_input('input a word>')
    print wordlist

    global g_pswlist
    g_pswlist = []
    for word in wordlist:
        g_pswlist.append(word)

    for word1 in wordlist:
        for word2 in wordlist:
            locallist = [word1, word2]
            if IsElementUniq(locallist):
                tmp = word1 + word2
                if len(tmp) < 20:
                    g_pswlist.append(tmp)

    for word1 in wordlist:
        for word2 in wordlist:
            for word3 in wordlist:
                locallist = [word1, word2, word3]
                if IsElementUniq(locallist):
                    tmp = word1 + word2 + word3
                    if len(tmp) < 20:
                        g_pswlist.append(tmp)

發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 武山县| 敖汉旗| 临漳县| 新竹市| 吉首市| 郯城县| 建湖县| 永年县| 鄄城县| 新源县| 临泉县| 万载县| 东安县| 儋州市| 湛江市| 汝城县| 马边| 高雄县| 绵阳市| 盱眙县| 新绛县| 韶关市| 汉沽区| 武山县| 修武县| 波密县| 安达市| 上思县| 湛江市| 区。| 辉南县| 邓州市| 克山县| 松阳县| 历史| 华坪县| 长海县| 始兴县| 汉寿县| 自治县| 融水|