Getting more info on radpostauth
Hi Alan and dear list. Currently I use freeradius 3 to authenticate wifi users using SQL module. After each authentication request I can see a new entry on radpostauth table in my database.... Everything OK. Radpostauth table has the information about username, pass, reply message and authdate. I need a record about the callingstationid parameter that is arriving in each request. So, If I create a new row in that table, how can I modify the SQL query in order to insert the callingstationid in that table? Thanks a lot -- *C. Andrés Gómez R.*
Take a look at mods-config/sql/main/<SQL flavour>/queries.conf under the post-auth section. /K On Tue, Sep 29, 2020 at 2:08 AM Andrés Gómez <andres.gomez.ruiz@gmail.com> wrote:
Hi Alan and dear list.
Currently I use freeradius 3 to authenticate wifi users using SQL module. After each authentication request I can see a new entry on radpostauth table in my database.... Everything OK.
Radpostauth table has the information about username, pass, reply message and authdate.
I need a record about the callingstationid parameter that is arriving in each request. So, If I create a new row in that table, how can I modify the SQL query in order to insert the callingstationid in that table?
Thanks a lot
-- *C. Andrés Gómez R.* - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Hello dear Andres Gomez and list members, I have added additional fields like *ip*, *mac *into *radpostauth *table and modified mysql queries as below accordingly at */etc/freeradius/mods-config/sql/main/mysql/queries.conf* file. post-auth { query = "\ INSERT INTO ${..postauth_table} \ (username, pass, reply, authdate, *ip*, *mac*) \ VALUES ( \ '%{SQL-User-Name}', \ '%{%{User-Password}:-%{Chap-Password}}', \ '%{reply:Packet-Type} - %{reply:Reply-Message}', \ '%S', \ * '%{NAS-IP-Address}', \ '%{Calling-Station-Id}' \* )" } I hope this is gonna help you and be informative. Have a great day all folks. İbrahim AKŞİT Best Regards and Wishes Yours Sincerely. On Tue, Sep 29, 2020 at 3:09 AM Andrés Gómez <andres.gomez.ruiz@gmail.com> wrote:
Hi Alan and dear list.
Currently I use freeradius 3 to authenticate wifi users using SQL module. After each authentication request I can see a new entry on radpostauth table in my database.... Everything OK.
Radpostauth table has the information about username, pass, reply message and authdate.
I need a record about the callingstationid parameter that is arriving in each request. So, If I create a new row in that table, how can I modify the SQL query in order to insert the callingstationid in that table?
Thanks a lot
-- *C. Andrés Gómez R.* - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Thanks a lot İbrahim and Kristofer.
I think that is what i was looking for!!!
Best regards
Em ter., 29 de set. de 2020 às 01:55, Ibrahim AKSIT <ibrahimaksit@gmail.com>
escreveu:
> Hello dear Andres Gomez and list members,
>
> I have added additional fields like *ip*, *mac *into *radpostauth *table
> and modified mysql queries as below accordingly
> at */etc/freeradius/mods-config/sql/main/mysql/queries.conf* file.
>
>
> post-auth {
> query = "\
> INSERT INTO ${..postauth_table} \
> (username, pass, reply, authdate, *ip*, *mac*) \
> VALUES ( \
> '%{SQL-User-Name}', \
> '%{%{User-Password}:-%{Chap-Password}}', \
> '%{reply:Packet-Type} - %{reply:Reply-Message}', \
> '%S', \
>
> * '%{NAS-IP-Address}', \ '%{Calling-Station-Id}' \*
> )"
> }
>
> I hope this is gonna help you and be informative.
> Have a great day all folks.
>
> İbrahim AKŞİT
>
> Best Regards and Wishes
> Yours Sincerely.
>
>
> On Tue, Sep 29, 2020 at 3:09 AM Andrés Gómez <andres.gomez.ruiz@gmail.com>
> wrote:
>
> > Hi Alan and dear list.
> >
> > Currently I use freeradius 3 to authenticate wifi users using SQL module.
> > After each authentication request I can see a new entry on radpostauth
> > table in my database.... Everything OK.
> >
> > Radpostauth table has the information about username, pass, reply message
> > and authdate.
> >
> > I need a record about the callingstationid parameter that is arriving in
> > each request. So, If I create a new row in that table, how can I modify
> the
> > SQL query in order to insert the callingstationid in that table?
> >
> > Thanks a lot
> >
> >
> > --
> > *C. Andrés Gómez R.*
> > -
> > List info/subscribe/unsubscribe? See
> > http://www.freeradius.org/list/users.html
> -
> List info/subscribe/unsubscribe? See
> http://www.freeradius.org/list/users.html
--
*C. Andrés Gómez R.*
participants (3)
-
Andrés Gómez -
Ibrahim AKSIT -
Kristofer Hallin