Hi, i would like to be able to forward an internal ports of users through the VPN. The idea is that a user picks 2-3 ports (or maybe just one) tcp port out of a given port-pool, and when he connects to the VPN, this portforwarding is established for him. Any idea how to do this? I'm using pptpd with freeradius + mysql. thanks for a hint. cheers, --sascha
On Sun, Aug 10, 2008 at 10:15:31AM +0400, Sascha Kiefer wrote:
Hi,
i would like to be able to forward an internal ports of users through the VPN. The idea is that a user picks 2-3 ports (or maybe just one) tcp port out of a given port-pool, and when he connects to the VPN, this portforwarding is established for him. Any idea how to do this? I'm using pptpd with freeradius + mysql.
This is not a freeradius question. If you want to run a script on the VPN server and have it access values from the radius reply, see "man pppd-radius" and look at the ip-up script.
thanks for a hint. cheers, --sascha - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
All, I'm using 'redundant' to failover from SQL to Filebased Authentication At the time, my MySQL Server is gone, FR is waiting for minutes to go on to the next step... ++- entering policy redundant expand: %{User-Name} -> fred rlm_sql (sql_access-1): sql_set_user escaped user --> fred rlm_sql (sql_access-1): Reserving sql socket id: 4 expand: SELECT id,UserName,Attribute,Value,op FROM radcheck WHERE UserName = '%{SQL-User-Name}' and VolumeBucket = '%{VolumeBucket}' ORDER BY id -> SELECT id,UserName,Attribute,Value,op FROM radcheck WHERE UserName = 'fred' ORDER BY id rlm_sql_mysql: query: SELECT id,UserName,Attribute,Value,op FROM radcheck WHERE UserName = 'fred' ORDER BY id rlm_sql_mysql: MYSQL check_error: 2006, returning SQL_DOWN rlm_sql (sql_access-1): Attempting to connect rlm_sql_mysql #4 rlm_sql_mysql: Starting connect to MySQL server for #4 rlm_sql_mysql: Couldn't connect socket to MySQL server radiususer@db-access-1:acctopus_te rlm_sql_mysql: Mysql error 'Can't connect to MySQL server on 'db-access-1' (146)' rlm_sql (sql_access-1): Failed to connect DB handle #4 rlm_sql (sql_access-1): reconnect failed, database down? rlm_sql_getvpdata: database query error rlm_sql (sql_access-1): SQL query error; rejecting user rlm_sql (sql_access-1): Released sql socket id: 4 +++[sql_access-1] returns fail expand: %{User-Name} -> fred rlm_sql (sql_access-2): sql_set_user escaped user --> 'fred' rlm_sql (sql_access-2): Trying to (re)connect unconnected handle 4.. rlm_sql (sql_access-2): Attempting to connect rlm_sql_mysql #4 rlm_sql_mysql: Starting connect to MySQL server for #4 'db-acceees-1' is the hostname from hosts file, it is the machine itselv 'db-acceees-2' is the hostname from hosts file, it is the other machine, containing a replik... If up Accounting went throug the redeundant directly into the file... Without waisting time. I have configured: For access: redundant { sql_access-1 sql_access-2 ok } files For Accounting: redundant { sql_accounting detail } Are there any reconnect options beside connect_failure_retry_delay = 60 ? Thaks Stefan
Stefan A. wrote:
I'm using 'redundant' to failover from SQL to Filebased Authentication
At the time, my MySQL Server is gone, FR is waiting for minutes to go on to the next step...
It's likely DNS.
Accounting went throug the redeundant directly into the file... Without waisting time.
Maybe because it already did DNS lookups, and those queries were cached. Alan DeKok.
Thanks, Alan, but I'm using /etc/hosts for this boxes... And my nsswich has 'hosts: files dns ' So, I'd sys no DNS at all... Ad it worked immediately after starting the mysql server Anything els to check? Regards Stefan
-----Original Message----- From: freeradius-users-bounces+a.freeradius=premit.de@lists.freeradi us.org [mailto:freeradius-users-bounces+a.freeradius=premit.de@lists. freeradius.org] On Behalf Of Alan DeKok Sent: Monday, August 11, 2008 7:52 AM To: FreeRadius users mailing list Subject: Re: Redundant waits for minutes to failover
Stefan A. wrote:
I'm using 'redundant' to failover from SQL to Filebased Authentication
At the time, my MySQL Server is gone, FR is waiting for minutes to go on to the next step...
It's likely DNS.
Accounting went throug the redeundant directly into the file... Without waisting time.
Maybe because it already did DNS lookups, and those queries were cached.
Alan DeKok. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Stefan A. wrote:
So, I'd sys no DNS at all... Ad it worked immediately after starting the mysql server
Anything els to check?
No idea. FreeRADIUS has *no* minute-long waits coded into it. It's dependent on the host OS. So the problem is either DNS, or the MySQL client library is waiting minutes to notice that the MySQL server is down. Alan DeKok.
Sascha Kiefer wrote:
Hi,
i would like to be able to forward an internal ports of users through the VPN. The idea is that a user picks 2-3 ports (or maybe just one) tcp port out of a given port-pool, and when he connects to the VPN, this portforwarding is established for him. Any idea how to do this? I'm using pptpd with freeradius + mysql.
Any unused attribute + radattrs.so pppd's plugin + ip-up script with corresponding iptables. -- With best regards, Evgeniy Kozhuhovskiy, Leader of Services team, Minsk State Phony Network, RUE Beltelecom.
participants (5)
-
Alan DeKok -
Evgeniy Kozhuhovskiy -
Phil Mayers -
Sascha Kiefer -
Stefan A.