8
0
Fork 0
mirror of https://gitlab2.federez.net/re2o/re2o synced 2024-11-28 15:42:25 +00:00

Hot and dirty fix for Debian Buster.

This commit is contained in:
Hugo Levy-Falk 2019-09-01 15:38:34 +02:00 committed by root
parent 7f07b1ed48
commit e4d87a4fc7
2 changed files with 14 additions and 13 deletions

View file

@ -92,19 +92,20 @@ server radius-wifi {
authorize {
rewrite_calling_station_id
if (User-Name =~ /^(.*)@(.*)/){
if (User-Name !~ /^(.*)@(.*)example(.*)/){
update control{
Proxy-To-Realm := 'FEDEREZ'
}
}
# A decommenter pour activer le radius federez
#if (User-Name =~ /^(.*)@(.*)/){
# if (User-Name !~ /^(.*)@(.*)example(.*)/){
# update control{
# Proxy-To-Realm := 'FEDEREZ'
# }
# }
if ("%{request:User-Name}" =~ /^(.*)@(.*)example(.*)/){
update request{
Stripped-User-Name := "%{1}"
}
}
}
# if ("%{request:User-Name}" =~ /^(.*)@(.*)example(.*)/){
# update request{
# Stripped-User-Name := "%{1}"
# }
# }
#}
filter_username

View file

@ -78,7 +78,6 @@ import ldapdb.models
import ldapdb.models.fields
from re2o.settings import LDAP, GID_RANGES, UID_RANGES
from re2o.login import hashNT
from re2o.field_permissions import FieldPermissionModelMixin
from re2o.mixins import AclMixin, RevMixin
from re2o.base import smtp_check
@ -817,6 +816,7 @@ class User(RevMixin, FieldPermissionModelMixin, AbstractBaseUser,
def set_password(self, password):
""" A utiliser de préférence, set le password en hash courrant et
dans la version ntlm"""
from re2o.login import hashNT
super().set_password(password)
self.pwd_ntlm = hashNT(password)
return