-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Open
Description
First Steps
- Confirmed issue not posted previously.
- Confirmed wiki does not contain answers.
- Checking FAQ.
- BeEF Version: Latest
- Ruby Version: 3.2.3
- Browser Details: Firefox (Linux)
- Operating System: Linux
Configuration
- BeEF configuration changes? No
- Enabled/disabled extensions? No
Steps to Reproduce
- Start BeEF server
- Hook a browser (Firefox)
- Start a CORS-enabled test server on port 8080:
python3 -c " from http.server import HTTPServer, SimpleHTTPRequestHandler class CORSHandler(SimpleHTTPRequestHandler): def end_headers(self): self.send_header('Access-Control-Allow-Origin', '*') super().end_headers() HTTPServer(('127.0.0.1', 8080), CORSHandler).serve_forever() "
- Execute Cross-Origin Scanner (CORS) module with:
- Scan IP range:
127.0.0.1-127.0.0.1 - Ports:
8080
- Scan IP range:
Error Description
The module crashes the BeEF server thread with an ActiveModel::UnknownAttributeError when attempting to save scan results to the database.
Console Error
ActiveModel::UnknownAttributeError: unknown attribute 'type' for BeEF::Core::Models::NetworkService.
NoMethodError: undefined method `type=' for #<BeEF::Core::Models::NetworkService id: nil, hooked_browser_id: 0, proto: "http", ip: "127.0.0.1", port: "8080", ntype: nil>
Did you mean? ntype=
Root Cause
The module's post_execute method in module.rb:24 attempts to create a NetworkService record using an attribute called type, but the model only has an attribute called ntype.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels