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

Client does not preserve headers on redirect #182

Open
berezovskyi opened this issue Apr 22, 2019 · 0 comments
Open

Client does not preserve headers on redirect #182

berezovskyi opened this issue Apr 22, 2019 · 0 comments

Comments

@berezovskyi
Copy link
Member

We simply set the new URL:

if (Response.Status.fromStatusCode(response.getStatus()).getFamily() == Status.Family.REDIRECTION) {
	url = response.getStringHeaders().getFirst(HttpHeaders.LOCATION);
	response.readEntity(String.class);
	redirect = true;
} 

At the very least, we should:

  1. Set the Referer header.
  2. Keep the cookies.
@berezovskyi berezovskyi transferred this issue from eclipse/lyo.client Aug 21, 2021
@berezovskyi berezovskyi added this to the 5.0 milestone Feb 12, 2022
@berezovskyi berezovskyi modified the milestones: 5.0, 5.x Jun 30, 2023
@berezovskyi berezovskyi modified the milestones: 5.x, 7.x Aug 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant