Credential Access
- Category
- Privilege Escalation
- Confidence
- 60% confidence
- Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
- Content
js const publicDns=async()=>[{address:'93.184.215.14',family:4}]; const response=(status=200,headers={})=>({status,headers:{'content-type':'text/html',...headers},body:Buffer.from('<title>Example</title>')}); test('only public HTTPS domains and port443 are admitted',()=>{ for(const url of ['http://example.org','file:///etc/passwd','https://127.0.0.1','https://2130706433','<redacted-url>]','https://***@example.org/','https://example.org:8443','https://a.local','https://a.internal','https://localhost','https://example.org./','https://example.org/\n'])assert.throws(()=>publicUrl(url)); assert.equal(publicUrl('https://example.org:443/path').href,'https://example.org/path'); }); test('private, reserved, multicast, metadata and transition IPs are refused',()=>{
