HelloZeroNet / HelloZeroNet/ZeroNet
Zeronet UI does not work without HTTP Accept header
- Dominant language
- JavaScript
- Stars
- 18.8k
- Forks
- 2.3k
- PR merge metrics
- No merged PRs in 30d
Description
### Step 1: Please describe your environment
* ZeroNet version: 0.6.2
* Operating system: Linux
* Web browser: Firefox
* Tor status: enabled
* Opened port: yes
* Special configuration: I2P Tunnel
### Step 2: Describe the problem:
Zeronet Ui expects HTTP `Accept` header to contain at least `text/html`. I2P tunnels remove `Accept` header from the request, which does not allow to access Zeronet due to the following check:
https://github.com/HelloZeroNet/ZeroNet/blob/master/src/Ui/UiRequest.py#L283
#### Steps to reproduce:
1. Send HTTP request without `Accept` HTTP header to Zeronet UI address
#### Observed Results:
Zeronet returns HTTP 403 `Invalid Accept header to load wrapper` error.
#### Expected Results:
Zeronet ignores absence of HTTP `Accept` header and continue to work.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start at src/Ui/UiRequest.py around line 283 and reproduce the issue by sending an HTTP request without an Accept header to the ZeroNet UI address. Verify that the request no longer returns HTTP 403 and that the UI remains accessible when the header is absent.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100