Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 30 Oct 2001 10:45:13 -0800 (PST)
From:      Julian Elischer <julian@elischer.org>
To:        QUEVEDO BUSTILLOS Jose Federico <quevedo6@cuimail.unige.ch>
Cc:        freebsd-net@FreeBSD.ORG
Subject:   Re: ng_pppoe accounting?
Message-ID:  <Pine.BSF.4.21.0110301010170.26174-100000@InterJet.elischer.org>
In-Reply-To: <Pine.SOL.3.96.1011030184354.6564B-100000@cuisuna.unige.ch>

next in thread | previous in thread | raw e-mail | index | archive | help


On Tue, 30 Oct 2001, QUEVEDO BUSTILLOS Jose Federico wrote:

>  
> Hi, 
> 
> I'm a newbie in netgraph structures and I will like to ask your advice
> about some PPPoE related ideas. 
> 
> I'm using a FreeBDS box with PPPoE installed and working as a gateway.  My
> goal is to establish basic administration and accounting for PPPoE users.
> 

You are using pppoed to offer pppoe service?

> The basic accounting needs (not commercial goals) are:  

As a server or as a client?

> 
> 1. Keep track of the MAC addresses and users names of the PPPoE
> connections to the gateway, store time connection of the session and
> traffic generated.

Is this the kind of logging you want?
(I don't have this.. I did it by hand)

13:23:20 2001-10-29   00:23:33:01:23:54 julian 192.168.1.1
13:24:30 2001-10-29   00:01:43:11:45:78 bob 192.168.1.3
13:25:11 2001-10-29   00:23:33:76:2:24 paul 192.168.1.5
13:35:10 2001-10-29   00:23:33:01:23:54 *close* 12334354 in 32412344 out
...

The ppp daemon could do this if it knew the associated link and could
retrieve the MAC address associated with it.

there are several roadblocks..
1/the ppp daemon doesn't keep a control socket associated with the
connection so it can't inquire about the MAC address.
2/ If it were to try create a new control socket, it could not connect it
to the existing data socket.

It may be possible that the ppp daemon might know the netgraph node name
for the data socket node, in which case it could get the information
requested.
This would require an answer from Brian



> 2. Dynamic assignation of IP address. (I think on two possibilities a)
> PPPoE assignation: when PADR arrives, the gw should look into a pool of IP
> adresses and assign one "before calling PPP". B) leave PPP the assignation
> and capture the IP in other way). 

I think you need to leave it to ppp.
but maybe ppp can become aware of teh MAc address.


> 
> Result: A log file produced with a session match of:
> 
> MAC add - IP add - username - time of session.
> 
> Should I touch the ng_pppoe code? or should I create a netgraph node to
> place between ng_node and ng_ppp? 
> Am I on the good way 

Probably not good to touch the pppoe code..
until you discuss it with Brian.
Then when you can agree on what needs to be changed we can change it.
the ppp code needs to be in charge..


> 
> Thanks in advance,
> 
> Federico Quevedo
>  
> .................................................................
> Federico Quevedo
> 
> 
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-net" in the body of the message
> 


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-net" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0110301010170.26174-100000>