Advertisement
imKobz

Untitled

Sep 12th, 2020 (edited)
168
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.83 KB | None | 0 0
  1. server default {
  2.  
  3. listen {
  4.  
  5. type = auth
  6. ipaddr = *
  7. port = 0
  8. limit {
  9. max_connections = 0
  10. lifetime = 0
  11. idle_timeout = 30
  12. }
  13. }
  14.  
  15. listen {
  16. ipaddr = *
  17. port = 0
  18. type = acct
  19.  
  20. limit {
  21.  
  22. }
  23. }
  24.  
  25. listen {
  26. type = auth
  27. ipv6addr = :: # any. ::1 == localhost
  28. port = 0
  29. limit {
  30. max_connections = 16
  31. lifetime = 0
  32. idle_timeout = 30
  33. }
  34. }
  35.  
  36. listen {
  37. ipv6addr = ::
  38. port = 0
  39. type = acct
  40.  
  41. limit {
  42.  
  43. }
  44. }
  45.  
  46. authorize {
  47.  
  48. filter_username
  49. preprocess
  50. chap
  51. mschap
  52. digest
  53. eap {
  54. ok = return
  55. }
  56.  
  57. sql
  58. expiration
  59. logintime
  60. pap
  61. }
  62.  
  63. authenticate {
  64. Auth-Type PAP {
  65. pap
  66. }
  67.  
  68. Auth-Type CHAP {
  69. chap
  70. }
  71.  
  72. Auth-Type MS-CHAP {
  73. mschap
  74. }
  75.  
  76. mschap
  77. digest
  78. eap
  79. }
  80.  
  81. preacct {
  82.  
  83. preprocess
  84. acct_unique
  85. suffix
  86. files
  87. }
  88.  
  89. accounting {
  90. sql
  91. if (Acct-Status-Type == Start) {
  92. update reply {
  93. Tmp-String-0 = "%{exec:/bin/bash /etc/freeradius/3.0/connect %{User-Name} 1}"
  94. }
  95. }
  96. if (Acct-Status-Type == Stop) {
  97. update reply {
  98. Tmp-String-0 = "%{exec:/bin/bash /etc/freeradius/3.0/disconnect %{User-Name} 0}"
  99. }
  100. }
  101. }
  102.  
  103. session {
  104. sql
  105. }
  106.  
  107. post-auth {
  108.  
  109. if (session-state:User-Name && reply:User-Name && request:User-Name && (reply:User-Name == request:User-Name)) {
  110. update reply {
  111. &User-Name !* ANY
  112. }
  113. }
  114. update {
  115. &reply: += &session-state:
  116. }
  117.  
  118. sql
  119. exec
  120. remove_reply_message_if_eap
  121. Post-Auth-Type REJECT {
  122. sql
  123. attr_filter.access_reject
  124. eap
  125. remove_reply_message_if_eap
  126. }
  127.  
  128. Post-Auth-Type Challenge {
  129.  
  130. }
  131.  
  132. }
  133.  
  134. pre-proxy {
  135.  
  136. }
  137.  
  138. post-proxy {
  139. eap
  140. }
  141. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement