Pick up changes in passwd file
Michael Schwartzkopff
ms at sys4.de
Tue Dec 8 11:16:45 CET 2020
On 08.12.20 11:08, Markus Gaugusch via Freeradius-Users wrote:
> Dear freeradius-experts,
>
> I'm using version 3.0.21, running in docker
> (freeradius/freeradius-server:latest-alpine).
>
> I want to use freeradius to authenticate users against entries in a
> file in the form "username:$2a$10$<bcrypt hash>".
>
> This works quite well, using the following stanza:
>
> passwd my_passwd {
> filename = /opt/etc/raddb/ext/pwd.txt
> format = "*User-Name:Crypt-Password:"
> hash_size = 100
> ignore_nislike = no
> allow_multiple_keys = no
> }
>
> However, when the file gets modified, the changes are not picked up by
> freeradius.
>
> I checked the FAQ [1], which suggests to use kill -HUP <PID>, but that
> doesn't work either:
>
> Do you have any hints for me to get this resolved? It works by
> restarting the docker container, but I'd rather avoid this if possible.
>
> Actually, my users are stored by a 3rd party application in a
> postgresql DB. This DB is using a different schema than radiusd (I
> checked [2]), so I decided to generate the file described above. If it
> would be easy to access the DB directly using custom SQL queries ONLY
> for usernames/passwords, that would be another option. I only need
> authentication, no accounting or any logging into the DB.
>
>
> kind regards,
> Markus
>
> [1]:
> https://wiki.freeradius.org/guide/FAQ#how-do-i_how-do-i-get-radius-to-pick-up-changes-in-the-raddb-users-file
> [2]:
> https://wiki.freeradius.org/guide/SQL-HOWTO-for-freeradius-3.x-on-Debian-Ubuntu
>
> -
> List info/subscribe/unsubscribe? See
> http://www.freeradius.org/list/users.html
radmin -e hup
The much (!) better way would be to adapt the sql module of you FR
server to reflect your database structure. Have a look in the module
config. It is really easy. When you compiled a script you already have
done 80% of the work.
Mit freundlichen Grüßen,
--
[*] sys4 AG
https://sys4.de, +49 (89) 30 90 46 64
Schleißheimer Straße 26/MG,80333 München
Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
Vorstand: Patrick Ben Koetter, Marc Schiffbauer, Wolfgang Stief
Aufsichtsratsvorsitzender: Florian Kirstein
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freeradius.org/pipermail/freeradius-users/attachments/20201208/4971066d/attachment.sig>
More information about the Freeradius-Users
mailing list