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

bogus Authorization headers causes internal server error #178

Closed
alexskr opened this issue Dec 12, 2023 · 0 comments
Closed

bogus Authorization headers causes internal server error #178

alexskr opened this issue Dec 12, 2023 · 0 comments
Assignees

Comments

@alexskr
Copy link
Member

alexskr commented Dec 12, 2023

API server throws 500 error instead of 401 when API calls are made with incorrectly set Authorization headers. System errors out when it doesn't find the expected token string in the header

E, [2023-12-11T16:34:19.453357 #23461] ERROR -- : app error: undefined method `gsub' for nil:NilClass (NoMethodError)
E, [2023-12-11T16:34:19.453496 #23461] ERROR -- : /srv/ontoportal/ontologies_api/shared/bundle/ruby/2.7.0/bundler/gems/ontologies_linked_data-9487c7f73e68/lib/ontologies_linked_data/security/authorization.rb:83:in `find_apikey'
E, [2023-12-11T16:34:19.453556 #23461] ERROR -- : /srv/ontoportal/ontologies_api/shared/bundle/ruby/2.7.0/bundler/gems/ontologies_linked_data-9487c7f73e68/lib/ontologies_linked_data/security/authorization.rb:22:in `call'
E
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

No branches or pull requests

1 participant