# MySQL 8.0 Root 密码在线破解

bash

# 测试用户booboo的账号密码情况

mysql> select user,host,authentication_string from mysql.user;
+—————————+—————-+————————————————————————————————————+
| user | host | authentication_string |
+—————————+—————-+————————————————————————————————————+
| booboo | % | $A$005$z1;I4T4DFutFGI2Bx8I44RVy7oa0lY6paOoRofbbNcnFKUVJ3ojJkDvCw8 | # 系统库mysql [root@foundation0 tmp]# ll /var/lib/mysql/mysql* -rw-r——-. 1 mysql mysql 25165824 9月 24 17:44 /var/lib/mysql/mysql.ibd srwxrwxrwx. 1 mysql mysql 0 6月 1 17:46 /var/lib/mysql/mysql.sock -rw———-. 1 mysql mysql 6 6月 1 17:46 /var/lib/mysql/mysql.sock.lock /var/lib/mysql/mysql: 总用量 28 -rw-r——-. 1 mysql mysql 5594 6月 1 17:46 general_log_202.sdi -rw-r——-. 1 mysql mysql 35 6月 1 17:46 general_log.CSM -rw-r——-. 1 mysql mysql 0 6月 1 17:46 general_log.CSV -rw-r——-. 1 mysql mysql 11803 6月 1 17:46 slow_log_203.sdi -rw-r——-. 1 mysql mysql 35 6月 1 17:46 slow_log.CSM -rw-r——-. 1 mysql mysql 0 6月 1 17:46 slow_log.CSV # 复制一份 mysql.ibd cp /var/lib/mysql/mysql.ibd /tmp/mysql.ibd.bac # hexdump 分析 hexdump -C mysql.ibd.bac > /tmp/mysql.ibd.hexdump.txt 006912f0 20 20 20 20 20 20 20 20 20 20 71 69 6e 78 69 20 | qinxi | 00691300 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | | 00691310 20 20 20 20 20 20 20 20 20 20 00 00 00 00 14 d7 | ……| 00691320 02 00 00 01 1e 14 56 02 02 02 02 02 02 02 02 02 |……V………| 00691330 02 01 02 02 02 02 02 02 02 02 02 02 02 02 02 02 |…………….| 00691340 02 02 02 02 01 00 00 00 00 00 00 00 00 00 00 00 |…………….| 00691350 00 00 00 00 00 63 61 63 68 69 6e 67 5f 73 68 61 |…..caching_sha| 00691360 32 5f 70 61 73 73 77 6f 72 64 20 20 20 20 20 20 |2_password | 00691370 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | | 00691390 20 20 20 20 20 24 41 24 30 30 35 24 21 3e 13 58 |$A$005$!>.X|
006913a0 6c 74 5d 39 62 42 2d 25 10 75 06 57 68 46 79 52 |lt]9bB-%.u.WhFyR|
006913b0 53 4d 4e 38 39 54 42 68 4a 53 35 67 5a 6c 72 53 |SMN89TBhJS5gZlrS|
006913c0 32 4d 55 59 2f 4c 77 4c 38 4c 37 4f 4e 68 47 72 |2MUY/LwL8L7ONhGr|
006913d0 67 4a 68 65 36 37 65 39 4c 79 36 01 5f 6a b1 2c |gJhe67e9Ly6._j.,|
006913e0 01 02 02 46 40 00 00 00 20 7c 00 00 60 fe 0c 25 |…F@… |....%|
006913f0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | |

006914e0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 6f | bo|
006914f0 6f 62 6f 6f 20 20 20 20 20 20 20 20 20 20 20 20 |oboo |
00691500 20 20 20 20 20 20 20 20 20 20 20 20 20 20 00 00 | ..|
00691510 00 00 14 e1 82 00 00 00 9f 01 10 01 01 01 01 01 |…………….|
00691520 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 |…………….|
00691530 01 01 01 01 01 01 01 01 01 00 00 00 00 00 00 00 |…………….|
00691540 00 00 00 00 00 00 00 00 00 63 61 63 68 69 6e 67 |………caching|
00691550 5f 73 68 61 32 5f 70 61 73 73 77 6f 72 64 20 20 |_sha2_password |
00691560 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | |

00691580 20 20 20 20 20 20 20 20 20 24 41 24 30 30 35 24 | $A$005$| 00691590 7a 31 03 3b 1b 71 49 34 1f 54 0e 34 44 46 75 74 |z1.;.qI4.T.4DFut| 006915a0 46 47 49 32 42 78 38 49 34 34 52 56 79 37 6f 61 |FGI2Bx8I44RVy7oa| 006915b0 30 6c 59 36 70 61 4f 6f 52 6f 66 62 62 4e 63 6e |0lY6paOoRofbbNcn| 006915c0 46 4b 55 56 4a 33 6f 6a 4a 6b 44 76 43 77 38 01 |FKUVJ3ojJkDvCw8.| 006915d0 5f 6c 6a 26 01 01 01 00 00 00 00 00 00 00 00 00 |_lj&…………| 006915e0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |…………….| * 00691580 20 20 20 20 20 24 41 24 30 30 35 24 21 3e 13 58 |$A$005$!>.X|
00691590 6c 74 5d 39 62 42 2d 25 10 75 06 57 68 46 79 52 |lt]9bB-%.u.WhFyR|
006915a0 53 4d 4e 38 39 54 42 68 4a 53 35 67 5a 6c 72 53 |SMN89TBhJS5gZlrS|
006915b0 32 4d 55 59 2f 4c 77 4c 38 4c 37 4f 4e 68 47 72 |2MUY/LwL8L7ONhGr|
006915c0 67 4a 68 65 36 37 65 39 4c 79 36 01 5f 6a b1 2c |gJhe67e9Ly6._j.,|
006915d0 01 02 02 46 40 00 00 00 20 7c 00 00 60 fe 0c 25 |…F@… |..`..%|
006915e0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | |