CompTIA PenTest+ Certification Exam PT0-002 Question # 80 Topic 9 Discussion

CompTIA PenTest+ Certification Exam PT0-002 Question # 80 Topic 9 Discussion

PT0-002 Exam Topic 9 Question 80 Discussion:
Question #: 80
Topic #: 9

After obtaining a reverse shell connection, a penetration tester runs the following command: www-data@server!2:sudo -1

User www-data may run the following commands on serverl2: (root) NOPASSWD: /usr/bin/vi

Which of the following is the fastest way to escalate privileges on this server?


A.

Editing the file /etc/passwd to add a new user with uid0


B.

Creating a Bash script, saving it on the /tmp folder, andthen running it


C.

Executing the command sudo vi -c ' Jbash'


D.

Editing the file/etc/sudoers to allow any command


Get Premium PT0-002 Questions

Contribute your Thoughts:


Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.