Re: SQL xlat not working

2009-04-01 Thread tnt
I can't get SQL xlat to work in the Clients file. I'm trying to do a DB
query for the Shared Secret.


And where did you find that it should work?

I'm getting invalid Message-Authenticator (Shared secret is incorrect)
errors.

You should fix client secret to match the server not other way round.

The select statement works fine when ran on my DB server.

Have any suggestions?

You can load clients from nas table. See read_clients setting near the
end of sql.conf file.

Ivan Kalik
Kalik Informatika ISP

-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


RE: SQL xlat not working

2009-04-01 Thread Eric Geier
 I can't get SQL xlat to work in the Clients file. I'm trying to do a
 DB
 query for the Shared Secret.
 
 
 And where did you find that it should work?

I've googled for it. Plus someone here had mentioned rlm_raw and use it
with a SQL xlat rule. I think I'm doing that, but it's not working. Please
let me know what might be holding it up. 

 I'm getting invalid Message-Authenticator (Shared secret is incorrect)
 errors.
 
 You should fix client secret to match the server not other way round.
 
 The select statement works fine when ran on my DB server.
 
 Have any suggestions?
 
 You can load clients from nas table. See read_clients setting near the
 end of sql.conf file.

That may work, but could I have the Name field represent something besides
the IP, like the NAS-Identifier?

Thanks!
Eric

-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


RE: SQL xlat not working

2009-04-01 Thread tnt
I've googled for it. Plus someone here had mentioned rlm_raw and use it
with a SQL xlat rule. I think I'm doing that, but it's not working. Please
let me know what might be holding it up.


Lack of rlm_raw? That doesn't come with the server.

 You can load clients from nas table. See read_clients setting near the
 end of sql.conf file.

That may work, but could I have the Name field represent something besides
the IP, like the NAS-Identifier?

No. Unless you alter source code. Patches are welcome.

Ivan Kalik
Kalik informatika ISP

-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


RE: SQL xlat not working

2009-04-01 Thread Eric Geier
 I've googled for it. Plus someone here had mentioned rlm_raw and use
 it
 with a SQL xlat rule. I think I'm doing that, but it's not working.
 Please
 let me know what might be holding it up.
 
 
 Lack of rlm_raw? That doesn't come with the server.

But even without using a raw attribute, the SQL xlat rule doesn't work, such
as:

client 192.168.0.1/32 {
secret  = %{sql:SELECT secret FROM APs WHERE NAS-Identifier='blah'
shortname   = testnet
}

When googling, I think I found that when using LDAP, I would have to change
a setting to get this workingI didn't find a similar setting for SQL.

  You can load clients from nas table. See read_clients setting near
 the
  end of sql.conf file.
 
 That may work, but could I have the Name field represent something
 besides
 the IP, like the NAS-Identifier?
 
 No. Unless you alter source code. Patches are welcome.

Is there a how to I can read to learn about this?

-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: SQL xlat not working

2009-04-01 Thread Alan DeKok
Eric Geier wrote:
 But even without using a raw attribute, the SQL xlat rule doesn't work, such
 as:
 
 client 192.168.0.1/32 {
   secret  = %{sql:SELECT secret FROM APs WHERE NAS-Identifier='blah'

  That doesn't work.  Not only that, nothing in the documentation leads
you to believe that it COULD work.

   shortname   = testnet
 }
 
 When googling, I think I found that when using LDAP, I would have to change
 a setting to get this workingI didn't find a similar setting for SQL.

  There isn't one.

 Is there a how to I can read to learn about this?

  The source code is freely available, and well commented.

  Alan DeKok.
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


SQL xlat not working

2009-03-31 Thread Eric Geier
I can't get SQL xlat to work in the Clients file. I'm trying to do a DB
query for the Shared Secret.

I'm getting invalid Message-Authenticator (Shared secret is incorrect)
errors.
The select statement works fine when ran on my DB server.

Have any suggestions?

Thanks, Eric

-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html