mirror of
https://gitlab.com/openconnect/ocserv.git
synced 2026-02-10 08:46:58 +08:00
The replaced keywords were put into brackets.
This commit is contained in:
@@ -297,10 +297,10 @@ route = 192.168.5.0/255.255.255.0
|
||||
#route-add-cmd = "ip route add %R dev %D"
|
||||
#route-del-cmd = "ip route delete %R dev %D"
|
||||
|
||||
# This option allows to forward a proxy. The special strings '%U'
|
||||
# and '%G', if present will be replaced by the username and group name.
|
||||
# This option allows to forward a proxy. The special strings '%{U}'
|
||||
# and '%{G}', if present will be replaced by the username and group name.
|
||||
#proxy-url = http://example.com/
|
||||
#proxy-url = http://example.com/%U/%G/hello
|
||||
#proxy-url = http://example.com/%{U}/%{G}/hello
|
||||
|
||||
#
|
||||
# The following options are for (experimental) AnyConnect client
|
||||
|
||||
@@ -392,10 +392,10 @@ route = 192.168.5.0/255.255.255.0
|
||||
#route-add-cmd = "ip route add %R dev %D"
|
||||
#route-del-cmd = "ip route delete %R dev %D"
|
||||
|
||||
# This option allows to forward a proxy. The special keywords '%U'
|
||||
# and '%G', if present will be replaced by the username and group name.
|
||||
# This option allows to forward a proxy. The special keywords '%{U}'
|
||||
# and '%{G}', if present will be replaced by the username and group name.
|
||||
#proxy-url = http://example.com/
|
||||
#proxy-url = http://example.com/%U/
|
||||
#proxy-url = http://example.com/%{U}/
|
||||
|
||||
#
|
||||
# The following options are for (experimental) AnyConnect client
|
||||
@@ -424,8 +424,8 @@ route = 192.168.5.0/255.255.255.0
|
||||
# authentication and prior to VPN tunnel establishment. You shouldn't
|
||||
# need to use this option normally; if you do and you think that
|
||||
# this may help others, please send your settings and reason to
|
||||
# the openconnect mailing list. The special keywords '%U'
|
||||
# and '%G', if present will be replaced by the username and group name.
|
||||
# the openconnect mailing list. The special keywords '%{U}'
|
||||
# and '%{G}', if present will be replaced by the username and group name.
|
||||
#custom-header = "X-My-Header: hi there"
|
||||
|
||||
@end example
|
||||
|
||||
@@ -1311,13 +1311,13 @@ char *replace_vals(worker_st *ws, const char *txt)
|
||||
if (ret < 0)
|
||||
return NULL;
|
||||
|
||||
ret = str_replace_str(&str, "%U", ws->username);
|
||||
ret = str_replace_str(&str, "%{U}", ws->username);
|
||||
if (ret < 0) {
|
||||
str_clear(&str);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
ret = str_replace_str(&str, "%G", ws->groupname);
|
||||
ret = str_replace_str(&str, "%{G}", ws->groupname);
|
||||
if (ret < 0) {
|
||||
str_clear(&str);
|
||||
return NULL;
|
||||
|
||||
Reference in New Issue
Block a user