Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feature] Added openwisp_radius installation #223

Closed
wants to merge 38 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
b1333c0
[feature] Added openwisp_radius installation
atb00ker Nov 29, 2020
4640bdc
Commented out mysql and postgres install.
nemesifier Dec 23, 2020
c36f1c8
Do not remove eap
nemesifier Dec 23, 2020
e989b1d
Do not modify clients (we'll configure sql module to read from DB)
nemesifier Dec 23, 2020
761a006
Avoid modifying the main radius config file since it shouldn't be needed
nemesifier Dec 23, 2020
055e443
Added possibility of turning off installation of freeradius
nemesifier Dec 23, 2020
ad13152
Add way to disable radius URLs if deployd on a different VM
nemesifier Dec 23, 2020
761327e
Simplified sql configuration
nemesifier Dec 23, 2020
31940d3
SQL: added read_clients = yes
nemesifier Dec 23, 2020
b6f9b3d
django-freeradius > openwisp-radius
nemesifier Dec 23, 2020
03156ab
Moved OPENWISP_USERS_AUTH_API out of the if openwisp_radius block
nemesifier Dec 23, 2020
a1e154e
Removed redundant urls
nemesifier Dec 23, 2020
c4b956b
Fixed redundant PRIVATE_STORAGE_ROOT definition
nemesifier Dec 24, 2020
21b2720
[chores] Install libpq-dev if using postgres
nemesifier Dec 24, 2020
c65d2bd
[feature] Added openwisp_radius installation
atb00ker Nov 29, 2020
fed2967
[radius] Removed database setup + minor
atb00ker Jan 1, 2021
6136f07
[chores] Import freeradius.yml only when openwisp2_radius is true
nemesifier Jan 7, 2021
6ea3bbe
[fix] Schedule openwisp-radius tasks only if radius enabled
nemesifier Jan 8, 2021
797e868
[radius] Removed database setup + minor
atb00ker Jan 1, 2021
69fad3e
[freeradius] Fix eap error
atb00ker Jan 9, 2021
37703eb
[fix] Fixed SQL parameters: host > server, user > login
nemesifier Jan 20, 2021
1332b1d
[chores] Added missing modules in authorize section
nemesifier Jan 20, 2021
c98e6c1
[chores] Fixed indentation of sql module
nemesifier Jan 20, 2021
b63c337
[fix] Fixed sql counter
nemesifier Jan 20, 2021
325ac68
[fix] Added patched postgresql counters
nemesifier Jan 21, 2021
7db00ab
[chores] Minor improvements
nemesifier Jan 21, 2021
f7f3468
[chores] Removed duplicated noresetcounter
nemesifier Jan 22, 2021
9c6ff64
[change] Adjusted interval of cron tasks
nemesifier Feb 5, 2021
3b035c5
[chores] Allow disabling openwisp_radius.tasks.delete_old_radacct
nemesifier Feb 5, 2021
1255daf
[chores] Added more notes to variables
nemesifier Feb 5, 2021
6680a18
[openwisp-radius] Add test to ensure freeradius is working
atb00ker Feb 8, 2021
ef14796
[chores] Added basic inner-tunnel
nemesifier Apr 24, 2021
8c0bbc8
[freeradius] Fixed problems prohibiting start
atb00ker Apr 28, 2021
9ab2950
Merge branch 'master' into openwisp_radius
nemesifier Jun 29, 2021
cd2eb08
Merge branch 'master' into openwisp_radius
nemesifier Aug 13, 2021
8bebc28
[fix] Added safe_characters to freeradius SQL conf
nemesifier Aug 13, 2021
2b717b1
Merge branch 'master' into openwisp_radius
nemesifier Sep 17, 2021
88c9acc
Merge branch 'master' into openwisp_radius
nemesifier Sep 17, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion tasks/freeradius.yml
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,6 @@
state: absent
with_items:
- "{{ freeradius_sites_enabled_dir }}/default"
- "{{ freeradius_sites_enabled_dir }}/inner-tunnel"

- name: Site configuration
template:
Expand All @@ -152,3 +151,12 @@
owner: freerad
group: freerad
notify: restart freeradius

- name: Inner tunnel
template:
src: freeradius/openwisp_site.j2
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@atb00ker isn't this wrong?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this was one of the causes of build failure,fixed it in the latest commit! 😄

dest: "{{ freeradius_sites_enabled_dir }}/inner-tunnel"
mode: 0640
owner: freerad
group: freerad
notify: restart freeradius
81 changes: 81 additions & 0 deletions templates/freeradius/inner-tunnel.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
server inner-tunnel {
listen {
ipaddr = 127.0.0.1
port = 18120
type = auth
}

authorize {
filter_username
rest

chap
mschap
suffix

update control {
&Proxy-To-Realm := LOCAL
}

eap {
ok = return
}

-ldap

pap

dailycounter
dailybandwidthcounter
noresetcounter
expiration
logintime
}

authenticate {
Auth-Type PAP {
pap
}

Auth-Type CHAP {
chap
}

Auth-Type MS-CHAP {
mschap
}
eap
}

session {}

post-auth {
if (0) {
update reply {
User-Name !* ANY
Message-Authenticator !* ANY
EAP-Message !* ANY
Proxy-State !* ANY
MS-MPPE-Encryption-Types !* ANY
MS-MPPE-Encryption-Policy !* ANY
MS-MPPE-Send-Key !* ANY
MS-MPPE-Recv-Key !* ANY
}
update {
&outer.session-state: += &reply:
}
}

Post-Auth-Type REJECT {
attr_filter.access_reject
update outer.session-state {
&Module-Failure-Message := &request:Module-Failure-Message
}
}
}

pre-proxy {}
post-proxy {
eap
}
}