You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: docs/Configuration.md
+16-1
Original file line number
Diff line number
Diff line change
@@ -78,6 +78,10 @@ openvpn:
78
78
# common-names:
79
79
# - "test"
80
80
# - "test2"
81
+
ccd:
82
+
enabled: false
83
+
token-claim: ""
84
+
path: "/etc/openvpn-auth-oauth2/"
81
85
common-name:
82
86
environment-variable-name: common_name
83
87
mode: plain
@@ -95,9 +99,10 @@ openvpn:
95
99
96
100
<!-- BEGIN USAGE -->
97
101
```
98
-
Usage of openvpn-auth-oauth2:
99
102
Documentation available at https://github.com/jkroepke/openvpn-auth-oauth2/wiki
100
103
104
+
Usage of ./openvpn-auth-oauth2:
105
+
101
106
--config string
102
107
path to one .yaml config file (env: CONFIG_CONFIG)
103
108
--debug.listen string
@@ -186,6 +191,12 @@ Documentation available at https://github.com/jkroepke/openvpn-auth-oauth2/wiki
186
191
Override the username of a session with the username from the token by using auth-token-user, if the client username is empty (env: CONFIG_OPENVPN_AUTH__TOKEN__USER) (default true)
187
192
--openvpn.bypass.common-names value
188
193
bypass oauth authentication for CNs. Comma separated list. (env: CONFIG_OPENVPN_BYPASS_COMMON__NAMES)
194
+
--openvpn.ccd.enabled
195
+
If true, openvpn-auth-oauth2 will read the CCD directory for additional configuration. This function mimic the client-config-dir directive in OpenVPN. (env: CONFIG_OPENVPN_CCD_ENABLED)
196
+
--openvpn.ccd.path string
197
+
Path to the CCD directory. openvpn-auth-oauth2 will look for an file with an .conf suffix and returns the content back. (env: CONFIG_OPENVPN_CCD_PATH) (default "/etc/openvpn-auth-oauth2/ccd/")
198
+
--openvpn.ccd.token-claim string
199
+
If non-empty, the value of the token claim is used to lookup the configuration file in the CCD directory. If empty, the common name is used. (env: CONFIG_OPENVPN_CCD_TOKEN__CLAIM)
Name of the environment variable in the OpenVPN management interface which contains the common name. If username-as-common-name is enabled, this should be set to 'username' to use the username as common name. Other values like 'X509_0_emailAddress' are supported. See https://openvpn.net/community-resources/reference-manual-for-openvpn-2-6/#environmental-variables for more information. (env: CONFIG_OPENVPN_COMMON__NAME_ENVIRONMENT__VARIABLE__NAME) (default "common_name")
191
202
--openvpn.common-name.mode value
@@ -317,3 +328,7 @@ See [Layout Customization](Layout%20Customization) for more information
317
328
## Non-interactive session refresh
318
329
319
330
See [Non-interactive session refresh](Non-interactive%20session%20refresh) for more information.
331
+
332
+
## Client specific configuration
333
+
334
+
See [Client specific configuration](Client%20specific%20configuration) for more information.
"bypass oauth authentication for CNs. Comma separated list.",
171
171
)
172
+
flagSet.Bool(
173
+
"openvpn.ccd.enabled",
174
+
Defaults.OpenVpn.CCD.Enabled,
175
+
"If true, openvpn-auth-oauth2 will read the CCD directory for additional configuration. This function mimic the client-config-dir directive in OpenVPN.",
176
+
)
177
+
flagSet.String(
178
+
"openvpn.ccd.path",
179
+
Defaults.OpenVpn.CCD.Path,
180
+
"Path to the CCD directory. openvpn-auth-oauth2 will look for an file with an .conf suffix and returns the content back.",
181
+
)
182
+
flagSet.String(
183
+
"openvpn.ccd.token-claim",
184
+
Defaults.OpenVpn.CCD.TokenClaim,
185
+
"If non-empty, the value of the token claim is used to lookup the configuration file in the CCD directory. If empty, the common name is used.",
0 commit comments