Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFC Violation - 401 Unauthorized not sending WWW-Authenticate to SUBSCRIBE messages #2640

Open
junction1153 opened this issue Nov 5, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@junction1153
Copy link

Describe the bug
Previously reported in ticket # 1779 but not addressed. When FS sends a 401 Unauthorized to a SUBSCRIBE request, the WWW-Authenticate string is missing. This is required per RFC RFC 3261 section 22.2

To Reproduce
Simply have an endpoint send a SUBSCRIBE for BLF. When the endpoint re-sends a subscribe after the sofia nonce expired, freeswitch will respond with 401 unauthorized

Expected behavior
WWW-Authenticate string should be received in the SIP message

Package version or git hash

  • Tested with 1.10.8 to 1.10.12, all easily reproduceable
@greenbea
Copy link
Contributor

I fixed this bug #2648

@junction1153
Copy link
Author

I can confirm that #2648 patches the mentioned issue

@themsley-voiceflex
Copy link

Also worth noting that some Fanvil phones will immediately retry the same SUBSCRIBE and get the same response, thus launching their own DoS attack in response to the 401. We had over 50 million SUBSCRIBEs a day due to this bug - I think from around 10 phones. Fanvil issued firmware updates to stop it from happening.

@greenbea
Copy link
Contributor

greenbea commented Dec 4, 2024

@themsley-voiceflex did you test the patch?

@volga629-1
Copy link

@greenbea I tested patch and fix works as intended. SUBSCRIBE in dialog get authenticated properly

Screenshot 2024-12-09 at 9 03 46 AM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants