Disclaimer This research was conducted strictly in a controlled lab environment (PG Practice). The purpose of this writeāup is to evaluate AIāassisted pentesting workflows, not to promote automation abuse or realāworld exploitation.
šÆ Objective
The goal of this exercise was not just to root the machine, but to evaluate:
- How effective HexStrike AI is when used as an assistant
- Where human judgment is still required
- Whether AI guidance can accelerate decisionāmaking without replacing fundamentals
As an OSCP graduate, my focus was on methodology, reasoning, and realism.
Initial Enumeration (HumanāDriven)
I began with standard enumeration:
- Nmap for port and service discovery
- Nikto for basic web vulnerability assessment
These steps were performed manually. While HexStrike can suggest enumeration, I intentionally controlled this phase to:
- Maintain accuracy
- Reduce noise
- Preserve situational awareness
š Lesson: AI is most effective after you understand the surface.

Proceeded with Nikto:

These are the commands run by hexstrike on my terminal:


š Credential Discovery (Manual Decision)
At this stage, HexStrike suggested bruteāforcing users. However, I intentionally did not let HexStrike bruteāforce credentials.
Why?
- AIādriven bruteāforcing can be timeāconsuming and noisy
- In real engagements, unnecessary bruteāforce is often discouraged
- Manual control allows better wordlist tuning
I manually bruteāforced and successfully discovered valid credentials.
š Reasoning: This is an example of human judgment overriding automation ā a recurring theme throughout the engagement.

Consulting HexStrike: "What Now?"
After gaining authenticated access, I asked HexStrike:
"What should I do next given that I can edit website themes?"
HexStrike correctly identified this as a webātoāRCE opportunity and suggested leveraging theme file modification for code execution.
This aligned perfectly with realāworld CMS exploitation scenarios.


š§Ŗ Payload Strategy: AI Guidance vs Human Preference
HexStrike suggested:
- Generating a PHP payload using msfvenom
- Saving it as
/tmp/shell.php

While valid, I chose a slightly different approach.
Why I deviated:
- I consistently use the PentestMonkey PHP reverse shell
- It is simple, readable, and reliable
- I understand its behavior deeply (important for debugging)
I:
- Copied the PentestMonkey PHP shell
- Updated the IP and port
- Inserted the payload into the
header.phptheme file as suggested by HexStrike
š Insight: AI suggestions are templates, not rules. Experienced operators adapt them to tools they trust.

Gaining a Reverse Shell
Steps executed:
- Started a Netcat listener on my chosen port
- Visited the vulnerable web page:
http://192.168.172.239- Successfully received a reverse shell
This confirmed:
- Payload placement was correct
- PHP execution context was valid
- Network connectivity was unrestricted
i get a rev shell

PostāExploitation Enumeration
Once inside the system, I followed standard procedure:
Uploaded linPEAS
- Enumerated:
- SUID binaries
- Writable paths
- Kernel/version weaknesses
This phase was humanācontrolled, but I used HexStrike to:
- Interpret findings
- Prioritize suspicious results
Privilege Escalation via SUID Binary
LinPEAS revealed a binary with the SUID bit enabled.

Rather than guessing, I asked HexStrike:
"How can this binary be abused?"
HexStrike provided:
- A specific exploitation technique
- A precise command to test privilege escalation
Upon executing the command:
- Privilege escalation succeeded
- Root access achieved


š§ Final Analysis: Did AI "Solve" the Box?
Short answer: No ā but it accelerated it significantly.
Breakdown:

HexStrike functioned as:
- A knowledge amplifier
- A decision validator
- A timeāsaver
Not a replacement.
š Key Lessons Learned
1ļøā£ AI excels at direction, not execution
HexStrike was best at:
- Suggesting logical next steps
- Explaining exploitation paths
- Reducing research time
2ļøā£ Human judgment is still critical
Key decisions ā bruteāforcing, payload choice, timing ā were humanāled.
3ļøā£ Blind automation is dangerous
Letting AI bruteāforce or exploit blindly:
- Increases noise
- Reduces learning
- Is unrealistic in real pentests
Future Advice: How to Use AI Correctly in Pentesting
If you're an OSCP student or junior pentester:
ā Use AI to:
- Interpret scan results
- Brainstorm exploit paths
- Explain why something works
- Improve writeāups and reporting
ā Don't use AI to:
- Replace enumeration
- Run uncontrolled bruteāforce
- Claim "fully automated pentesting"
Conclusion
AI tools like HexStrike do not replace pentesters ā but they absolutely reward those who already understand the fundamentals.
Used responsibly, AI becomes:
A force multiplier ā not a crutch.
This lab reinforced an important truth: Skill first. Automation second.