Skip to content

ACS Jsoup fetch runs into 403: Forbidden  #11682

Open
@viktorkrimstein

Description

@viktorkrimstein

JabRef version

5.15 (latest release)

Operating system

macOS

Details on version and operating system

macOS 14.6.1 build 23G93

Checked with the latest development build (copy version output from About dialog)

  • I made a backup of my libraries before testing the latest development version.
  • I have tested the latest development version and the problem persists

Steps to reproduce the behaviour

Issue Reproduction

  1. Run any test in src/test/java/org/jabref/logic/importer/fetcher/ACSTest.java
  2. Debug the retrieved document by the findByDOI() method in src/main/java/org/jabref/logic/importer/fetcher/ACS.java
  3. Notice that no matter the given DOI or URL to the method, the request runs into a HTTP 403 error code with the following message:
org.jsoup.HttpStatusException: HTTP error fetching URL. Status=403

Currently, the request through JSoup is ignoring any kind of HTTP error in line 54.
This seams in any way a wrong behavior, since the implementation ignores documents not found.
The retrieved document is still parsed and the method always returns an Optional.empty() rendering all test cases useless.

Steps taken so far

After some initial Googling, I found the settings for the User-Agent HTTP headers for the request.
It seams like a general problem with the ACS webserver.
The above error occurs on Windows, Linux virtual machines in diferent networks on the Azure Cloud as well as in the private home network.
So it seems that it is a general issue with ACS but should be fixed properly.

Using the default Chrome, Firefox and Safari browsers, no HTTP 403 occurs.
It should be investigated which HTTP headers are sent over the network for a sucessful retrieval.

Appendix

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions