[prev in list] [next in list] [prev in thread] [next in thread] 

List:       squid-users
Subject:    Re: [squid-users] External ACL Auth & Session DB for 100+ clients behind NAT
From:       Nishant Sharma <codemarauder () gmail ! com>
Date:       2012-05-30 15:52:25
Message-ID: CAMptfcf989cDHtrcfDiLc+kv3PZ9N=AY_0=4fpyfs936w1Lztw () mail ! gmail ! com
[Download RAW message or body]

On Sun, May 27, 2012 at 5:28 PM, Amos Jeffries <squid3@treenet.co.nz> wrote:
>> If you could send in sample strings - received and final expected
>> result, I can help with hacking Perl code.
>
> Thank you. Expected input is strings like:
>
> "1 foo bar"   -> channel-ID="1",  UUID="foo bar"
> "2 hello"       -> channel-ID="2", UUID="hello"
>
> Only numerics in the channel-ID, followed by one SP to separate them, then
> anything including more SP characters in the UUID portion.
>

my $string = "1 foo bar";
$string =~ m/^(\d+)\s(.*)$/;
my ($cid, $uuid) = ($1, $2);

Above code will give values for $cid and $uuid as:

$cid = 1
$uuid = "foo bar"

Let me know if that's as expected.

>
> code submission and auditing procedures are detailed at:
> http://wiki.squid-cache.org/MergeProcedure
>

Thanks for this. I will submit it soon.

regards,
Nishant
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic