<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Calibri, sans-serif; "><div>Hi,</div><div><br></div><div>I'm trying to check if a user coming from a particular NAS, then check in that user is also a member of a GROUP associated to that NAS, else REJECT access.</div><div><br></div><div>Authorise section…..</div><div><br></div><div><div>if(NAS-Identifier == 'OpenVPN' && SQL-GROUP == 'openvpn') { </div><div> update reply {</div><div> Reply-Message := "OpenVPN AuthCheck OK"</div><div> }</div><div> reject</div><div>}</div></div><div>…</div><div><br></div><div><div><div>Wed Feb 1 00:37:59 2012 : Info: ++? if (NAS-Identifier == 'OpenVPN' && SQL-GROUP == 'openvpn')</div><div>Wed Feb 1 00:37:59 2012 : Info: ? Evaluating (NAS-Identifier == 'OpenVPN' ) -> TRUE</div><div>Wed Feb 1 00:37:59 2012 : Info: sql_groupcmp</div><div>Wed Feb 1 00:37:59 2012 : Info: <span class="Apple-tab-span" style="white-space:pre"> </span>expand: %{User-Name} -> nev</div><div>Wed Feb 1 00:37:59 2012 : Info: sql_set_user escaped user --> 'nev'</div><div>Wed Feb 1 00:37:59 2012 : Debug: rlm_sql (sql): Reserving sql socket id: 1</div><div>Wed Feb 1 00:37:59 2012 : Info: <span class="Apple-tab-span" style="white-space:pre"> </span>expand: SELECT groupname FROM radusergroup WHERE username = '%{SQL-User-Name}' ORDER BY priority -> SELECT groupname FROM radusergroup WHERE username = 'nev' ORDER BY priority</div><div>Wed Feb 1 00:37:59 2012 : Debug: rlm_sql (sql): Released sql socket id: 1</div><div>Wed Feb 1 00:37:59 2012 : Info: sql_groupcmp finished: User is NOT a member of group openvpn</div></div></div><div><br></div><div><br></div><div>As user 'nev' is not part of group 'openvpn' but is trying to access NAS 'OpenVPN' it should Reject the login and not go any further, but it does not.</div><div><br></div><div>I know I'm missing something, so any help would be greatly appreciated.</div><div><br></div><div>Thx</div><div>Nev</div><div><br></div><div><br></div></body></html>