info: name: Disable HTTP TRACE Method in Apache2 author: pussycat0x severity: high description: | The HTTP TRACE method should be disabled to prevent Cross-Site Tracing (XST) attacks. remediation: | Add 'TraceEnable Off' in the Apache configuration file and restart the service. reference: - https://wiki.devsecopsguides.com/docs/checklists/apache/ - https://httpd.apache.org/docs/2.4/mod/core.html#traceenable metadata: verified:true tags: audit,config,auth,apache,hardening
javascript: -pre-condition: | isPortOpen(Host,Port); code: | var m = require("nuclei/ssh"); var c = m.SSHClient(); c.Connect(Host,Port,User,Pass); const ApacheConfig = c.Run(Code) ApacheConfig let result =""; if (ApacheConfig.includes("<Directory") &&!ApacheConfig.includes("TraceEnable On")) { result +="Disable HTTP Trace Method"; } else { exit(); } result