diff --git a/seed/applicationservice/2022.03.08/dovecot/dictionaries/22_dovecot.xml b/seed/applicationservice/2022.03.08/dovecot/dictionaries/26_dovecot.xml
similarity index 98%
rename from seed/applicationservice/2022.03.08/dovecot/dictionaries/22_dovecot.xml
rename to seed/applicationservice/2022.03.08/dovecot/dictionaries/26_dovecot.xml
index fff7eca5..c711bea9 100644
--- a/seed/applicationservice/2022.03.08/dovecot/dictionaries/22_dovecot.xml
+++ b/seed/applicationservice/2022.03.08/dovecot/dictionaries/26_dovecot.xml
@@ -86,6 +86,9 @@
+
+ False
+
diff --git a/seed/applicationservice/2022.03.08/gitea/dictionaries/31_gitea.xml b/seed/applicationservice/2022.03.08/gitea/dictionaries/31_gitea.xml
index 2a22d6ee..8855276f 100644
--- a/seed/applicationservice/2022.03.08/gitea/dictionaries/31_gitea.xml
+++ b/seed/applicationservice/2022.03.08/gitea/dictionaries/31_gitea.xml
@@ -89,7 +89,7 @@
43
gitea_lfs_jwt_secret
-
+
revprox_client_external_domainnames
revprox_client_location
user/oauth2/
diff --git a/seed/applicationservice/2022.03.08/lemonldap/dictionaries/70_lemonldap_ng.xml b/seed/applicationservice/2022.03.08/lemonldap/dictionaries/70_lemonldap_ng.xml
index 816e2aaa..9532c815 100644
--- a/seed/applicationservice/2022.03.08/lemonldap/dictionaries/70_lemonldap_ng.xml
+++ b/seed/applicationservice/2022.03.08/lemonldap/dictionaries/70_lemonldap_ng.xml
@@ -22,6 +22,11 @@
+
+
+ False
+
+
1
@@ -33,7 +38,15 @@
all
+
+
+
+ ldap_server_address
+ ldap_group
+ ldapclient_group_dn
+
+
diff --git a/seed/applicationservice/2022.03.08/lemonldap/extras/oauth2/00_oauth2.xml b/seed/applicationservice/2022.03.08/lemonldap/extras/oauth2/00_oauth2.xml
index 7c72c61d..924ef09e 100644
--- a/seed/applicationservice/2022.03.08/lemonldap/extras/oauth2/00_oauth2.xml
+++ b/seed/applicationservice/2022.03.08/lemonldap/extras/oauth2/00_oauth2.xml
@@ -2,17 +2,15 @@
-
-
-
-
+
+
+
+
-
-
- users
-
+
+
@@ -21,15 +19,5 @@
-
-
- domain_name_eth0
-
- remote
- cleartext
- hide_secret
- oauth2.oauth2_.secret_
-
-
diff --git a/seed/applicationservice/2022.03.08/lemonldap/templates/lmConf-1.json b/seed/applicationservice/2022.03.08/lemonldap/templates/lmConf-1.json
index 832fe91c..c7dd06fd 100644
--- a/seed/applicationservice/2022.03.08/lemonldap/templates/lmConf-1.json
+++ b/seed/applicationservice/2022.03.08/lemonldap/templates/lmConf-1.json
@@ -22,7 +22,7 @@ commentStartToken = §
"givenName" : "givenName",
"home" : "homeDirectory"
},
- "ldapGroupBase" : "%%ldapclient_base_dn",
+ "ldapGroupBase" : "%%ldapclient_group_dn",
"ldapGroupAttributeName" : "member",
"ldapGroupAttributeNameUser" : "cn",
"ldapGroupAttributeNameGroup" : "dn",
@@ -72,8 +72,7 @@ commentStartToken = §
},
"%%domain" : {
"^/logout" : "logout_sso",
-§ FIXME "default" : "$groups eq %%external['family_' + %%key]"
- "default" : "accept"
+ "default" : "$groups eq \"%%external['family_' + %%key]\""
%%domains.append(%%domain)%slurp
%end if
%end for
diff --git a/seed/applicationservice/2022.03.08/lemonldap/templates/portal-nginx.conf b/seed/applicationservice/2022.03.08/lemonldap/templates/portal-nginx.conf
index 9ab815cf..1ec0e3a4 100644
--- a/seed/applicationservice/2022.03.08/lemonldap/templates/portal-nginx.conf
+++ b/seed/applicationservice/2022.03.08/lemonldap/templates/portal-nginx.conf
@@ -15,24 +15,24 @@ upstream llng_portal_upstream {
server unix:/var/run/llng-fastcgi-server/llng-fastcgi.sock;
}
-server {
- listen 127.0.0.1:80;
- server_name localhost;
- root /usr/share/lemonldap-ng/portal/htdocs/;
- if ($uri !~ ^/((static|javascript|favicon|.internal-well-known).*|.*\.psgi)) {
- rewrite ^/(.*)$ /index.psgi/$1 break;
- }
- location ~ ^(?/.*\.psgi)(?:$|/) {
- include /etc/nginx/fastcgi_params;
- fastcgi_pass llng_portal_upstream;
- fastcgi_param REQUEST_URI /.well-known/openid-configuration;
- fastcgi_param HTTP_HOST %%domain_name_eth0;
- fastcgi_param LLTYPE psgi;
- fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
- fastcgi_split_path_info ^(.*\.psgi)(/.*)$;
- fastcgi_param PATH_INFO $fastcgi_path_info;
- }
-}
+# GNUNUX server {
+# GNUNUX listen 127.0.0.1:80;
+# GNUNUX server_name localhost;
+# GNUNUX root /usr/share/lemonldap-ng/portal/htdocs/;
+# GNUNUX if ($uri !~ ^/((static|javascript|favicon|.internal-well-known).*|.*\.psgi)) {
+# GNUNUX rewrite ^/(.*)$ /index.psgi/$1 break;
+# GNUNUX }
+# GNUNUX location ~ ^(?/.*\.psgi)(?:$|/) {
+# GNUNUX include /etc/nginx/fastcgi_params;
+# GNUNUX fastcgi_pass llng_portal_upstream;
+# GNUNUX fastcgi_param REQUEST_URI /.well-known/openid-configuration;
+# GNUNUX fastcgi_param HTTP_HOST %%domain_name_eth0;
+# GNUNUX fastcgi_param LLTYPE psgi;
+# GNUNUX fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
+# GNUNUX fastcgi_split_path_info ^(.*\.psgi)(/.*)$;
+# GNUNUX fastcgi_param PATH_INFO $fastcgi_path_info;
+# GNUNUX }
+# GNUNUX }
server {
# GNUNUX listen 80;
diff --git a/seed/applicationservice/2022.03.08/mailman/dictionaries/31_mailman.xml b/seed/applicationservice/2022.03.08/mailman/dictionaries/31_mailman.xml
index 1c71bb94..b7055029 100644
--- a/seed/applicationservice/2022.03.08/mailman/dictionaries/31_mailman.xml
+++ b/seed/applicationservice/2022.03.08/mailman/dictionaries/31_mailman.xml
@@ -65,7 +65,7 @@
revprox_client_external_domainnames
revprox_client_location
- /accounts/risotto/login/
+ accounts/risotto/login/
oauth2_client_external
diff --git a/seed/applicationservice/2022.03.08/nginx-common/dictionaries/20_nginx.xml b/seed/applicationservice/2022.03.08/nginx-common/dictionaries/20_nginx.xml
index 70bab6ec..2279a56b 100644
--- a/seed/applicationservice/2022.03.08/nginx-common/dictionaries/20_nginx.xml
+++ b/seed/applicationservice/2022.03.08/nginx-common/dictionaries/20_nginx.xml
@@ -11,19 +11,22 @@
/sysusers.d/nginx.conf
/tmpfiles.d/nginx.conf
revprox_ca_file
- /etc/pki/tls/certs/nginx.crt
- /etc/pki/tls/private/nginx.key
+ /etc/pki/tls/certs/nginx.crt
+ /etc/pki/tls/private/nginx.key
+
+ False
+
+
+ False
+
/usr/share/nginx/html
-
- False
-
128
128
@@ -40,14 +43,17 @@
Fedora
nginx_fedora
+ nginx_default
+ nginx_default_http
+ nginx_default_https
nginx_default
-
+
False
- nginx_https
+ nginx_default_https
tls_ca_directory
diff --git a/seed/applicationservice/2022.03.08/nginx-common/templates/nginx.conf b/seed/applicationservice/2022.03.08/nginx-common/templates/nginx.conf
index 9d4ecd95..758cb4de 100644
--- a/seed/applicationservice/2022.03.08/nginx-common/templates/nginx.conf
+++ b/seed/applicationservice/2022.03.08/nginx-common/templates/nginx.conf
@@ -52,7 +52,7 @@ http {
# for more information.
include /etc/nginx/conf.d/*.conf;
%if %%os_name == 'Fedora'
- %if %%nginx_default
+ %if %%nginx_default_http
server {
listen 80;
listen [::]:80;
@@ -73,7 +73,7 @@ http {
%end if
# Settings for a TLS enabled server.
#
- %if %%nginx_https
+ %if %%nginx_default_https
server {
listen 443 ssl http2;
server_name %%domain_name_eth0;
diff --git a/seed/applicationservice/2022.03.08/nginx-https/dictionaries/25_nginx.xml b/seed/applicationservice/2022.03.08/nginx-https/dictionaries/25_nginx.xml
index 65ec9bb6..f908f0b5 100644
--- a/seed/applicationservice/2022.03.08/nginx-https/dictionaries/25_nginx.xml
+++ b/seed/applicationservice/2022.03.08/nginx-https/dictionaries/25_nginx.xml
@@ -7,7 +7,7 @@
-
+
True
diff --git a/seed/applicationservice/2022.03.08/nginx-reverse-proxy/dictionaries/25_nginx.xml b/seed/applicationservice/2022.03.08/nginx-reverse-proxy/dictionaries/25_nginx.xml
index 910feb89..515ff0b9 100644
--- a/seed/applicationservice/2022.03.08/nginx-reverse-proxy/dictionaries/25_nginx.xml
+++ b/seed/applicationservice/2022.03.08/nginx-reverse-proxy/dictionaries/25_nginx.xml
@@ -18,6 +18,9 @@
+
+ True
+
diff --git a/seed/applicationservice/2022.03.08/oauth2-client/dictionaries/30_oauth2_client.xml b/seed/applicationservice/2022.03.08/oauth2-client/dictionaries/30_oauth2_client.xml
index ffc384a7..9d3d0bcb 100644
--- a/seed/applicationservice/2022.03.08/oauth2-client/dictionaries/30_oauth2_client.xml
+++ b/seed/applicationservice/2022.03.08/oauth2-client/dictionaries/30_oauth2_client.xml
@@ -8,7 +8,7 @@
-
+
@@ -37,72 +37,44 @@
OAuth2
oauth2_client_server_domainname
-
- oauth2_client_server_domainname
- oauth2
- domain_name_eth0
+
+ domain_name_eth0
oauth2_client_id
-
- oauth2_client_server_domainname
- oauth2_secret
- oauth2_client_id
+
+ domain_name_eth0
+ oauth2_client_id
+ remote
+ cleartext
+ hide_secret
oauth2_client_secret
-
- oauth2_client_server_domainname
- external_domainname
+
+ oauth2_client_server_domainname
+ domain_name_eth0
+ oauth2
+ oauth2_client_secret
+ oauth2_secret
+ oauth2_client_name
+ oauth2_name
+ oauth2_client_description
+ oauth2_description
+ oauth2_client_external
+ oauth2_external
+ oauth2_client_family
+ oauth2_family
+ oauth2_client_category
+ oauth2_category
+ oauth2_client_logo
+ oauth2_logo
+ oauth2_client_login
+ oauth2_login
+ True
+ oauth2_client_token_signature_algo
+ oauth2_token_signature_algo
+ external_domainname
oauth2_server_domainname
-
- oauth2_client_server_domainname
- oauth2_name
- oauth2_client_id
- oauth2_client_name
-
-
- oauth2_client_server_domainname
- oauth2_description
- oauth2_client_id
- oauth2_client_description
-
-
- oauth2_client_server_domainname
- oauth2_category
- oauth2_client_id
- oauth2_client_category
-
-
- oauth2_client_server_domainname
- oauth2_external
- oauth2_client_id
- oauth2_client_external
-
-
- oauth2_client_server_domainname
- oauth2_logo
- oauth2_client_id
- oauth2_client_logo
-
-
- oauth2_client_server_domainname
- oauth2_family
- oauth2_external
- oauth2_client_id
- oauth2_client_family
-
-
- oauth2_client_server_domainname
- oauth2_login
- oauth2_client_id
- oauth2_client_login
-
-
- oauth2_client_server_domainname
- oauth2_token_signature_algo
- oauth2_client_id
- oauth2_client_token_signature_algo
-
revprox_client_external_domainnames
revprox_client_location
diff --git a/seed/applicationservice/2022.03.08/oauth2-client/funcs/oauth2_client.py b/seed/applicationservice/2022.03.08/oauth2-client/funcs/oauth2_client.py
index 29b1f55f..47647fed 100644
--- a/seed/applicationservice/2022.03.08/oauth2-client/funcs/oauth2_client.py
+++ b/seed/applicationservice/2022.03.08/oauth2-client/funcs/oauth2_client.py
@@ -8,3 +8,18 @@ def calc_oauth2_client_external(external, location, *extras):
if isinstance(external, list):
return [f'https://{exter}{location[0]}' + ''.join(extras) for exter in external]
return f'https://{external}{location[0]}' + ''.join(extras)
+
+
+def calc_oauth2_client_login(external, location, *extras):
+ if not external or not location or None in extras:
+ return
+ if isinstance(external, list):
+ return f'https://{external[0]}{location[0]}' + ''.join(extras)
+ return f'https://{external}{location[0]}' + ''.join(extras)
+
+
+@_multi_function
+def calc_oauth2_families(families: list) -> list:
+ def _calc_family(family):
+ return family if family else 'users'
+ return [_calc_family(family) for family in families]
diff --git a/seed/applicationservice/2022.03.08/openldap/dictionaries/21_openldap-server.xml b/seed/applicationservice/2022.03.08/openldap/dictionaries/21_openldap-server.xml
index 4354fb32..d0f712d5 100644
--- a/seed/applicationservice/2022.03.08/openldap/dictionaries/21_openldap-server.xml
+++ b/seed/applicationservice/2022.03.08/openldap/dictionaries/21_openldap-server.xml
@@ -75,7 +75,10 @@
-
+
+
+
+
@@ -89,6 +92,20 @@
domain_name_eth0
ldapclient_base_dn
+
+ ldapclient_base_dn
+ True
+ ldap_account_dn
+
+
+ ldapclient_base_dn
+ True
+ ldap_group_dn
+
+
+ ldapclient_base_dn
+ ldap_user_dn
+
cn=admin
ldapclient_base_dn
diff --git a/seed/applicationservice/2022.03.08/openldap/templates/config_acl.ldif b/seed/applicationservice/2022.03.08/openldap/templates/config_acl.ldif
index 86e1c008..30123bd5 100644
--- a/seed/applicationservice/2022.03.08/openldap/templates/config_acl.ldif
+++ b/seed/applicationservice/2022.03.08/openldap/templates/config_acl.ldif
@@ -13,7 +13,7 @@ olcAccess: {0}to attrs=userPassword
by self write
by anonymous auth
by * none
-olcAccess: {1}to dn.subtree="%%calc_ldapclient_base_dn(%%ldapclient_base_dn, family_name=None, group=True)"
+olcAccess: {1}to dn.subtree="%%ldap_group_dn"
%for group in %%groups
by dn="%%group" read
%end for
@@ -21,7 +21,7 @@ olcAccess: {1}to dn.subtree="%%calc_ldapclient_base_dn(%%ldapclient_base_dn, fam
%set %%aclidx = 2
%for %%family, %%remotes in %%dns.items()
%if %%family == 'all'
-olcAccess: {%%aclidx}to dn.subtree="%%calc_ldapclient_base_dn(%%ldapclient_base_dn, family_name=None, base=True)"
+olcAccess: {%%aclidx}to dn.subtree="%%ldap_account_dn"
%else
olcAccess: {%%aclidx}to dn.subtree="%%calc_ldapclient_base_dn(%%ldapclient_base_dn, %%family)"
%end if
diff --git a/seed/applicationservice/2022.03.08/openldap/templates/users.ldif b/seed/applicationservice/2022.03.08/openldap/templates/users.ldif
index 76848136..03c6f1d3 100644
--- a/seed/applicationservice/2022.03.08/openldap/templates/users.ldif
+++ b/seed/applicationservice/2022.03.08/openldap/templates/users.ldif
@@ -23,13 +23,13 @@ objectClass: inetOrgPerson
%end for
# Accounts
-dn: %%calc_ldapclient_base_dn(%%ldapclient_base_dn, family_name=None, base=True)
+dn: %%ldap_account_dn
ou: accounts
objectClass: top
objectClass: organizationalUnit
## Accounts users
-%set %%users = %%calc_ldapclient_base_dn(%%ldapclient_base_dn, family_name=None)
+%set %%users = %%ldap_user_dn
dn: %%users
ou: users
objectClass: top
@@ -100,7 +100,7 @@ objectClass: inetLocalMailRecipient
%end for
%end for
## Groups
-%set %%groupdn = %%calc_ldapclient_base_dn(%%ldapclient_base_dn, family_name=None, group=True)
+%set %%groupdn = %%ldap_group_dn
dn: %%groupdn
ou: groups
objectClass: top
diff --git a/seed/applicationservice/2022.03.08/openldap/templates/users_mod.ldif b/seed/applicationservice/2022.03.08/openldap/templates/users_mod.ldif
index 90427daf..9ff3b249 100644
--- a/seed/applicationservice/2022.03.08/openldap/templates/users_mod.ldif
+++ b/seed/applicationservice/2022.03.08/openldap/templates/users_mod.ldif
@@ -8,7 +8,7 @@ userPassword:: %%ssha_encode(%%accounts['remote_' + %%name]['password_' + %%name
%end for
# Users
-%set %%users = %%calc_ldapclient_base_dn(%%ldapclient_base_dn, '')
+%set %%users = %%ldap_user_dn
%for %%user in %%accounts.users.ldap_user_mail
dn: cn=%%user,%%users
changetype: modify
diff --git a/seed/applicationservice/2022.03.08/postgresql-client/dictionaries/23_postgresql.xml b/seed/applicationservice/2022.03.08/postgresql-client/dictionaries/23_postgresql.xml
index b58a2c73..9a64f739 100644
--- a/seed/applicationservice/2022.03.08/postgresql-client/dictionaries/23_postgresql.xml
+++ b/seed/applicationservice/2022.03.08/postgresql-client/dictionaries/23_postgresql.xml
@@ -20,30 +20,24 @@
+
+ domain_name_eth0
+ pg_client_username
+
zone_name_eth0
Postgresql
pg_client_server_domainname
-
- pg_client_server_domainname
- clients
- domain_name_eth0
- pg_client_username
-
-
- pg_client_server_domainname
- client_password
- pg_client_username
+
+ pg_client_server_domainname
+ domain_name_eth0
+ clients
+ ip_eth0
+ client_ip
+ client_password
pg_client_password
-
- pg_client_server_domainname
- client_ip
- ip_eth0
- pg_client_username
- pg_client_password
-
pg_client_username
pg_client_database
diff --git a/seed/applicationservice/2022.03.08/roundcube/dictionaries/31_roundcube.xml b/seed/applicationservice/2022.03.08/roundcube/dictionaries/31_roundcube.xml
index 1250b6c3..a5afc3d7 100644
--- a/seed/applicationservice/2022.03.08/roundcube/dictionaries/31_roundcube.xml
+++ b/seed/applicationservice/2022.03.08/roundcube/dictionaries/31_roundcube.xml
@@ -39,6 +39,7 @@
+
@@ -77,6 +78,10 @@
roundcube_domains
revprox_client_external_domainnames
+
+ roundcube_family
+ oauth2_client_family
+
roundcube_family
ldapclient_family