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

Rewrite html responses from POST requests #421

Closed
oschaaf opened this Issue Jul 6, 2013 · 3 comments

Comments

Projects
None yet
2 participants
@oschaaf
Copy link
Member

oschaaf commented Jul 6, 2013

Currently, when we receive a POST request we never rewrite the response.
I think we could safely rewrite POST requests that result in a 200/OK response.
Comparing mod_pagespeed, I can't find code that restricts rewriting in this case.

Reported at https://groups.google.com/forum/#!topic/ngx-pagespeed-discuss/LiWQI7wRBJo

@jeffkaufman

This comment has been minimized.

Copy link
Contributor

jeffkaufman commented Jul 8, 2013

Looking at the apache implementation and proxy_interface, I think what this was supposed to do is only handle HEAD and GET requests for resources. For HTML we shouldn't care about request method.

@oschaaf

This comment has been minimized.

Copy link
Member

oschaaf commented Jul 8, 2013

@jeffkaufman Should I drop the check for the request method altogether for HTML? Or is this fine as-is?

I'm a bit anxious to drop the check on requests method altogether right now, as we should probably test less commonly used methods like OPTIONS/PUT/DELETE etc to make sure that nginx doesn't throw something we don't expect at us?

@jeffkaufman

This comment has been minimized.

Copy link
Contributor

jeffkaufman commented Jul 8, 2013

What if we just do this instead? #428

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment