Check if Origin is the same as request Hostname

I've added a check that doesn't treat the request as Cors if the Origin header is the same as the requested Host. This can happen on form submits that sends both the referal and the Origin header even if it's just a redirect within the same host.