Feb 25, 2013; 10:21
Marc Vos
Lasso9 take 12: client_ip and client_address
Hi,
According to the documentation (http://www.lassosoft.com/lassoDocs/languageReference/obj/client_ip), comparison with wildcards is possible.
We found two things with client_ip:
1) comparison does not work as in L8,
2) an error inside client_ip
------------------------------------------------------
When I run this snippet in Lasso 8:
[
var('x' = 0);
protect;
handle_error;
error_currentError;' @ ';$x;
/handle_error;
// This string normally comes from a database
local('ip' = '127.0.*,192.*,::1');
iterate(#ip->split(','), local('tmp'));
$x = loop_count;
if(client_ip == #tmp);
loop_count;') client_ip matches ';#tmp;' is OK.<br>';
/if;
/iterate;
/protect;
]
I get this output:
3) client_ip matches ::1 is OK.
------------------------------------------------------
When I run the same snippet in Lasso9,
I get this output:
Found non-keyword parameter at a keyword-only position @ 1
When I change 'client_ip' into 'client_address', the code works and gives the same result as with L8:
3) client_address matches ::1 is OK.
If I put ::1 in front of the string:
local('ip' = '::1,127.0.*,192.*');
and run the code, I get this output:
1) client_ip matches ::1 is OK.
Found non-keyword parameter at a keyword-only position @ 2
So there is clearly a code-flaw inside client_ip.
Is anybody else seeing this?
- -
Thanks,
Marc
#############################################################
This message is sent to you because you are subscribed to
the mailing list Lasso
Lasso@lists.lassosoft.com
To unsubscribe, E-mail to: <Lasso-unsubscribe@lists.lassosoft.com>
Send administrative queries to <Lasso-request@lists.lassosoft.com>
Feb 26, 2013; 07:28
Rick Draper
RE: Lasso9 take 12: client_ip and client_address
Feb 26, 2013; 07:34
Rick Draper
RE: Lasso9 take 12: client_ip and client_address
Feb 26, 2013; 00:02
Marc Vos
Re: Lasso9 take 12: client_ip and client_address