mirror of
https://github.com/jakobadam/RDSFactor.git
synced 2025-06-11 06:54:29 +02:00
Using IsValid on the RadiusPacket
This commit is contained in:
parent
8bbd742aaa
commit
6afe01e932
2 changed files with 10 additions and 14 deletions
|
@ -118,11 +118,19 @@ Public Class CICRadarR
|
|||
' will fire up the callback procedure. Invalid requests are dropped, per RFC.
|
||||
Private Sub ProcessPacket1812(ByVal packet As RADIUSPacket)
|
||||
'Console.WriteLine("packet " & Now)
|
||||
ProcessPacket(radius1812, packet)
|
||||
If packet.IsValid Then
|
||||
ProcessPacket(radius1812, packet)
|
||||
Else
|
||||
Console.WriteLine("Packet is not valid. Dropping.")
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub ProcessPacket1645(ByVal packet As RADIUSPacket)
|
||||
ProcessPacket(radius1645, packet)
|
||||
If packet.IsValid Then
|
||||
ProcessPacket(radius1645, packet)
|
||||
Else
|
||||
Console.WriteLine("Packet is not valid. Dropping.")
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub AccessLog(ByVal message)
|
||||
|
|
|
@ -30,10 +30,6 @@ Public Class RDSHandler
|
|||
End Sub
|
||||
|
||||
Public Sub ProcessRequest()
|
||||
If ValidPacket() = False Then
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
ExtractAttributes()
|
||||
|
||||
If mIsAppLaunchRequest Then
|
||||
|
@ -231,14 +227,6 @@ Public Class RDSHandler
|
|||
Return email
|
||||
End Function
|
||||
|
||||
Private Function ValidPacket()
|
||||
If mPacket.UserName Is Nothing Then
|
||||
Console.WriteLine("Not a valid radius packet.. No username present.. Drop!")
|
||||
Return False
|
||||
End If
|
||||
Return True
|
||||
End Function
|
||||
|
||||
Private Sub ExtractAttributes()
|
||||
packetUsername = mPacket.UserName.ToLower
|
||||
packetPassword = mPacket.UserPassword
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue