Hi Luke,

Here is a very basic squid module... I borrowed most all of the code
from one of the squid redirector modules.

#include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <ctype.h>

#define BUFFER_SIZE             (16*1024)

// Process lines of the form 'URL ip-address/fqdn ident method'
int main() {
    char buf[BUFFER_SIZE];
    char query[BUFFER_SIZE];
    char *s, *t;
    int tlu = 0;
    const char delimiters[] = " ";
    char *url, *ipaddress, *cp;

    /* make standard output line buffered */
    if (setvbuf(stdout, NULL, _IOLBF, 0) != 0)
        return 1;

    /* scan standard input */
    while (fgets(buf, BUFFER_SIZE, stdin) != NULL) {
      /* check for too long urls */
      if (strchr(buf, '\n') == NULL) {
          tlu = 1;
          continue;
      }
      if (tlu)
          goto dont_redirect;

      url = strtok (buf, delimiters);
      ipaddress = strtok (NULL, delimiters);

      // here you have the MSISDN and you need to use whatever to go
and get the MSISDN from wherever...

      dont_redirect:
        tlu = 0;
        (void) printf("\n");
    }

    return 0;
}


On 1/31/06, luke devon <[EMAIL PROTECTED]> wrote:
> H i ,
>
> Storing radius acct info is done , now i need to develop / have the other
> intermediate module to hook the msisdn and parse it into the proxy headers .
>
> my proxy is squid , how can i do that ? do i have to follow huge programming
> here ?
>
> How can you help me ?
>
> Are using , any third party module ?
>
> Thank you,
> Luke.
>
> Send instant messages to your online friends http://uk.messenger.yahoo.com

Reply via email to