exam questions

Exam PT0-002 All Questions

View all questions & answers for the PT0-002 exam

Exam PT0-002 topic 1 question 67 discussion

Actual exam question from CompTIA's PT0-002
Question #: 67
Topic #: 1
[All PT0-002 Questions]

A penetration tester was able to gain access successfully to a Windows workstation on a mobile client's laptop.
Which of the following can be used to ensure the tester is able to maintain access to the system?

  • A. schtasks /create /sc /ONSTART /tr C:\Temp|WindowsUpdate.exe
  • B. wmic startup get caption,command
  • C. crontab -l; echo ג€@reboot sleep 200 && ncat -lvp 4242 -e /bin/bashג€) | crontab 2>/dev/null
  • D. sudo useradd -ou 0 -g 0 user
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
Pokok2021
Highly Voted 1 year, 6 months ago
Window - should be schtasks. Crontab in Linux.
upvoted 17 times
RightAsTain
1 year, 6 months ago
No brainer!
upvoted 4 times
...
...
Treebeard88
Highly Voted 1 year, 4 months ago
Selected Answer: A
Windows is sctasks - Crontab is Linux
upvoted 8 times
...
NONS3c
Most Recent 4 days, 23 hours ago
Selected Answer: A
i thought the. c is correct but after i read it cerfully it said windows so on windows we use schtasks for automating
upvoted 1 times
...
bieecop
8 months, 2 weeks ago
Selected Answer: A
The "schtasks" command is used to manage scheduled tasks in Windows. By creating a new scheduled task with the "/sc ONSTART" option, the task will be triggered when the system starts up, ensuring persistence. The "/tr" option is used to specify the command or program to be executed by the scheduled task. In this case, the command "C:\Temp\WindowsUpdate.exe" is specified. The tester can replace this with a backdoor or a malicious payload that allows them to maintain access to the compromised system.
upvoted 1 times
...
cy_analyst
11 months, 3 weeks ago
Selected Answer: A
This command creates a scheduled task that runs a program every time the system starts. In this case, it creates a task that runs a program located in the C:\Temp folder named WindowsUpdate.exe. By using this command, the penetration tester can ensure that their backdoor program will run every time the system starts, allowing them to maintain access to the system.
upvoted 1 times
...
firmzeal
12 months ago
Selected Answer: C
Option A: schtasks /create /sc /ONSTART /tr C:\Temp|WindowsUpdate.exe creates a scheduled task that runs on system startup, but it does not ensure the penetration tester maintains access to the system. Option C: crontab -l; echo ג€@reboot sleep 200 && ncat -lvp 4242 -e /bin/bashג€) | crontab 2>/dev/null creates a new cron job that listens on port 4242 and launches a reverse shell on incoming connections. This command ensures that the penetration tester maintains access to the system even if they lose their initial foothold.
upvoted 1 times
firmzeal
12 months ago
Option C is Correct
upvoted 1 times
OnA_Mule
11 months, 1 week ago
It's only correct for Linux. It is definitely not correct for WIndows. A is the answer
upvoted 2 times
...
...
...
nickwen007
1 year ago
This code is attempting to use the schtasks command to create a scheduled task. The schtasks command is a Windows command line utility used to manage scheduled tasks. This command can be used to automate certain tasks in order to make them run on a regular basis, such as running Windows updates at a certain time of day. The /create argument creates a new scheduled task, the /sc argument specifies the schedule for the task, the /ONSTART argument specifies when the task should start (in this case when the computer starts), and the /tr argument specifies which command or program to run.
upvoted 4 times
[Removed]
1 year ago
what you think about Question 66 ?
upvoted 2 times
...
...
petercorn
1 year, 5 months ago
Selected Answer: A
crontab for linux
upvoted 4 times
...
ryanzou
1 year, 6 months ago
Selected Answer: A
A is correct
upvoted 5 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago