0

I am looking at my IIS web log and notice some log records with an sc-status of 302.

Screenshot of IIS web log subsample

I did research and am only more confused.

At first, it looks simple, if a little vague.

"This is an example of industry practice contradicting the standard. [...] Therefore, HTTP/1.1 added status codes 303 and 307 to distinguish between the two behaviours.[25] However, some Web applications and frameworks use the 302 status code as if it were the 303."

While I understand the concept, I am not sure which meaning to apply when viewing an IIS web log. Do I treat the 302 status code as a 303 ("See Other" -- a way to redirect to a new URL) or as a 307 ("Temporary Redirect")?

1 Answers1

2

307 causes a redirect using the same "verb" that the original url was requested with. That allows POST data to be preserved. By contrast, 301/302 will always cause a GET of the new url, losing any POST data that may have been present.

As well, with 301/302, the browser can cache the response and always go to the new url, bypassing the original url. 307 requires that the original URL be hit again, even if it does end up being another redirect.

Marc B
  • 356,200
  • 43
  • 426
  • 500