From d05a8836f29d41ec4a423d4f44dcbb93a8bdd759 Mon Sep 17 00:00:00 2001 From: Vivien Kraus Date: Thu, 1 Jul 2021 16:41:20 +0200 Subject: Switch to AGPL --- guix/vkraus/services/webid-oidc.scm | 46 +++++++++++++++++++++++++++++++++---- 1 file changed, 41 insertions(+), 5 deletions(-) (limited to 'guix/vkraus/services') diff --git a/guix/vkraus/services/webid-oidc.scm b/guix/vkraus/services/webid-oidc.scm index 984eced..641c700 100644 --- a/guix/vkraus/services/webid-oidc.scm +++ b/guix/vkraus/services/webid-oidc.scm @@ -1,3 +1,19 @@ +;; webid-oidc, implementation of the Solid specification +;; Copyright (C) 2020, 2021 Vivien Kraus + +;; This program is free software: you can redistribute it and/or modify +;; it under the terms of the GNU Affero General Public License as +;; published by the Free Software Foundation, either version 3 of the +;; License, or (at your option) any later version. + +;; This program is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU Affero General Public License for more details. + +;; You should have received a copy of the GNU Affero General Public License +;; along with this program. If not, see . + (define-module (vkraus services webid-oidc) #:use-module (gnu services) #:use-module (gnu services shepherd) @@ -16,6 +32,8 @@ webid-oidc-issuer-configuration? (webid-oidc webid-oidc-issuer-configuration-webid-oidc (default webid-oidc)) + (complete-corresponding-source + webid-oidc-issuer-configuration-complete-corresponding-source) (issuer webid-oidc-issuer-configuration-issuer) (key-file webid-oidc-issuer-configuration-key-file (default "/var/lib/webid-oidc/issuer/key.jwk")) @@ -37,6 +55,8 @@ webid-oidc-reverse-proxy-configuration? (webid-oidc webid-oidc-reverse-proxy-configuration-webid-oidc (default webid-oidc)) + (complete-corresponding-source + webid-oidc-reverse-proxy-configuration-complete-corresponding-source) (port webid-oidc-reverse-proxy-port (default 8090)) (inbound-uri webid-oidc-reverse-proxy-configuration-inbound-uri) (outbound-uri webid-oidc-reverse-proxy-configuration-outbound-uri) @@ -52,6 +72,8 @@ webid-oidc-hello-configuration? (webid-oidc webid-oidc-hello-configuration-webid-oidc (default webid-oidc)) + (complete-corresponding-source + webid-oidc-hello-configuration-complete-corresponding-source) (port webid-oidc-hello-configuration-port (default 8089)) (extra-options webid-oidc-hello-configuration-extra-options @@ -63,6 +85,8 @@ webid-oidc-client-service-configuration? (webid-oidc webid-oidc-client-service-configuration-webid-oidc (default webid-oidc)) + (complete-corresponding-source + webid-oidc-client-service-configuration-complete-corresponding-source) (client-id webid-oidc-client-service-configuration-client-id) (redirect-uri webid-oidc-client-service-configuration-redirect-uri) (client-name webid-oidc-client-service-configuration-client-name (default "Example Solid App")) @@ -78,6 +102,8 @@ webid-oidc-server-configuration? (webid-oidc webid-oidc-server-configuration-webid-oidc (default webid-oidc)) + (complete-corresponding-source + webid-oidc-server-configuration-complete-corresponding-source) (server-name webid-oidc-server-configuration-server-name) (key-file webid-oidc-server-configuration-key-file (default "/var/lib/webid-oidc/server/key.jwk")) @@ -98,6 +124,7 @@ make-webid-oidc-issuer-configuration webid-oidc-issuer-configuration? webid-oidc-issuer-configuration-webid-oidc + webid-oidc-issuer-configuration-complete-corresponding-source webid-oidc-issuer-configuration-issuer webid-oidc-issuer-configuration-key-file webid-oidc-issuer-configuration-subject @@ -112,6 +139,7 @@ make-webid-oidc-reverse-proxy-configuration webid-oidc-reverse-proxy-configuration? webid-oidc-reverse-proxy-configuration-webid-oidc + webid-oidc-reverse-proxy-configuration-complete-corresponding-source webid-oidc-reverse-proxy-configuration-port webid-oidc-reverse-proxy-configuration-inbound-uri webid-oidc-reverse-proxy-configuration-outbound-uri @@ -122,6 +150,7 @@ make-webid-oidc-hello-configuration webid-oidc-hello-configuration? webid-oidc-hello-configuration-webid-oidc + webid-oidc-hello-configuration-complete-corresponding-source webid-oidc-hello-configuration-port webid-oidc-hello-configuration-extra-options @@ -129,6 +158,7 @@ make-webid-oidc-client-service-configuration webid-oidc-client-service-configuration? webid-oidc-client-service-configuration-webid-oidc + webid-oidc-client-service-configuration-complete-corresponding-source webid-oidc-client-service-configuration-client-id webid-oidc-client-service-configuration-redirect-uri webid-oidc-client-service-configuration-client-name @@ -140,6 +170,7 @@ make-webid-oidc-server-configuration webid-oidc-server-configuration? webid-oidc-server-configuration-webid-oidc + webid-oidc-server-configuration-complete-corresponding-source webid-oidc-server-configuration-server-name webid-oidc-server-configuration-key-file webid-oidc-server-configuration-subject @@ -153,7 +184,7 @@ (define webid-oidc-issuer-shepherd-service (match-lambda (($ - webid-oidc issuer key-file subject password jwks-uri + webid-oidc ccs issuer key-file subject password jwks-uri authorization-endpoint-uri token-endpoint-uri port extra-options) (with-imported-modules @@ -181,6 +212,7 @@ (list (string-append #$webid-oidc "/bin/webid-oidc") "identity-provider" + "--complete-corresponding-source" #$ccs "--server-name" #$issuer "--key-file" #$key-file "--subject" #$subject @@ -204,7 +236,7 @@ (define webid-oidc-reverse-proxy-shepherd-service (match-lambda (($ - webid-oidc port inbound-uri outbound-uri header + webid-oidc ccs port inbound-uri outbound-uri header extra-options) (with-imported-modules (source-module-closure @@ -231,6 +263,7 @@ (list (string-append #$webid-oidc "/bin/webid-oidc") "reverse-proxy" + "--complete-corresponding-source" #$ccs "--port" (with-output-to-string (lambda () (display #$port))) "--server-name" #$inbound-uri "--backend-uri" #$outbound-uri @@ -250,7 +283,7 @@ (define webid-oidc-hello-shepherd-service (match-lambda (($ - webid-oidc port extra-options) + webid-oidc ccs port extra-options) (with-imported-modules (source-module-closure '((gnu build shepherd) @@ -275,6 +308,7 @@ (make-forkexec-constructor (list (string-append #$webid-oidc "/bin/webid-oidc-hello") + "--complete-corresponding-source" #$ccs "--port" (with-output-to-string (lambda () (display #$port))) #$@extra-options) #:user "webid-oidc" @@ -289,7 +323,7 @@ (define webid-oidc-client-service-shepherd-service (match-lambda (($ - webid-oidc client-id redirect-uri client-name client-uri port + webid-oidc ccs client-id redirect-uri client-name client-uri port extra-options) (with-imported-modules (source-module-closure @@ -314,6 +348,7 @@ (list (string-append #$webid-oidc "/bin/webid-oidc") "client-service" + "--complete-corresponding-source" #$ccs "--client-id" #$client-id "--redirect-uri" #$redirect-uri "--client-name" #$client-name @@ -332,7 +367,7 @@ (define webid-oidc-server-shepherd-service (match-lambda (($ - webid-oidc server-name key-file subject password jwks-uri + webid-oidc ccs server-name key-file subject password jwks-uri authorization-endpoint-uri token-endpoint-uri port extra-options) (with-imported-modules @@ -360,6 +395,7 @@ (list (string-append #$webid-oidc "/bin/webid-oidc") "server" + "--complete-corresponding-source" #$ccs "--server-name" #$server-name "--key-file" #$key-file "--subject" #$subject -- cgit v1.2.3