Fixed cookie session for IP based hosts
This commit is contained in:
parent
001e82a4b4
commit
b956acdf0c
|
@ -51,7 +51,8 @@ Resque::setBackend($redisHost.':'.$redisPort);
|
|||
define('COOKIE_DOMAIN',
|
||||
(
|
||||
$request->getServer('HTTP_HOST', null) === 'localhost' ||
|
||||
$request->getServer('HTTP_HOST', null) === 'localhost:'.$port
|
||||
$request->getServer('HTTP_HOST', null) === 'localhost:'.$port ||
|
||||
(filter_var($request->getServer('HTTP_HOST', null), FILTER_VALIDATE_IP) !== false)
|
||||
)
|
||||
? null
|
||||
: '.'.parse_url($scheme.'://'.$request->getServer('HTTP_HOST', ''), PHP_URL_HOST));
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Generated by pub on 2019-12-05 07:29:22.979822.
|
||||
# Generated by pub on 2019-12-05 18:55:11.878585.
|
||||
charcode:file:///Users/eldadfux/.pub-cache/hosted/pub.dartlang.org/charcode-1.1.2/lib/
|
||||
collection:file:///Users/eldadfux/.pub-cache/hosted/pub.dartlang.org/collection-1.14.12/lib/
|
||||
cookie_jar:file:///Users/eldadfux/.pub-cache/hosted/pub.dartlang.org/cookie_jar-1.0.1/lib/
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
Sign Up
|
||||
</h1>
|
||||
|
||||
<div class="text-danger margin-bottom-large" style="display: none;" data-ls-if="{{router.params.failure}} == 1">Registration Failed. Please try again later</div>
|
||||
<div class="text-danger margin-bottom-large" style="display: none;" data-ls-if="{{router.params.failure}} == 1" data-debug="1">Registration Failed. Please try again later</div>
|
||||
|
||||
<small class="pull-end">* All fields are required</small>
|
||||
|
||||
|
@ -20,7 +20,7 @@
|
|||
|
||||
<input name="confirm" type="hidden" data-ls-bind="{{env.PROTOCOL}}://{{env.DOMAIN}}/console">
|
||||
<input name="success" type="hidden" data-ls-bind="{{env.PROTOCOL}}://{{env.DOMAIN}}/console">
|
||||
<input name="failure" type="hidden" data-ls-bind="{{env.PROTOCOL}}://{{env.DOMAIN}}/auth/signup?failure=1">
|
||||
<input name="failure" type="hidden" data-ls-bind="{{env.PROTOCOL}}://{{env.DOMAIN}}/auth/signup?failure=1&">
|
||||
|
||||
<label>Name</label>
|
||||
<input name="name" type="text" autocomplete="name" placeholder="" required>
|
||||
|
|
Loading…
Reference in a new issue