Skip to content

fix: Include User-Agent header in OUI data download#3

Open
Cyberistic wants to merge 1 commit intoProfessionallyEvil:mainfrom
Cyberistic:patch-1
Open

fix: Include User-Agent header in OUI data download#3
Cyberistic wants to merge 1 commit intoProfessionallyEvil:mainfrom
Cyberistic:patch-1

Conversation

@Cyberistic
Copy link
Copy Markdown

Added User-Agent header to the request for OUI data.

fixes #2

Added User-Agent header to the request for OUI data.
Copilot AI review requested due to automatic review settings March 16, 2026 07:59
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the IEEE OUI download request in nmap_oui_update.py to include a User-Agent header, addressing IEEE rejecting automated downloads (HTTP 418) and unblocking nmap_oui_update runs.

Changes:

  • Add a User-Agent header to the IEEE OUI requests.get(...) call.
  • Keep existing download validation logic based on HTTP 200 and content check.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Comment thread nmap_oui_update.py
Comment on lines +100 to +101
headers = {"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36"}
res = requests.get(IEEE_URL, headers=headers)
Comment thread nmap_oui_update.py
dst = os.path.join(get_root_program_path(), OUI_DATA)
res = requests.get(IEEE_URL)
headers = {"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36"}
res = requests.get(IEEE_URL, headers=headers)
Comment thread nmap_oui_update.py
Comment on lines +100 to +101
headers = {"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36"}
res = requests.get(IEEE_URL, headers=headers)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ERROR: Got status code 418 while downloading

2 participants