From 662f69fae2b69cd967cde300d9753d5f726ebdb0 Mon Sep 17 00:00:00 2001 From: Emmanuel Garette Date: Fri, 7 Nov 2025 06:37:56 +0100 Subject: [PATCH] [tutorial v1.1_110)] xxx (config and doc) --- README.md | 76 +++++++++++++++++++++++++++++-------------------------- 1 file changed, 40 insertions(+), 36 deletions(-) diff --git a/README.md b/README.md index 588ab5e5..46458e2d 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ - [Summary](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/branch/1.1/README.md) -- [[tutorial v1.1_104] xxx](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_104/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_104~1..v1.1_104)) +- [[tutorial v1.1_105] xxx](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_105/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_105~1..v1.1_105)) -# [tutorial v1.1_105)] xxx +# [tutorial v1.1_110)] xxx -[View the diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_105~1..v1.1_105) +[View the diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_110~1..v1.1_110) ## Screenshot @@ -396,11 +396,36 @@ proxies: - WPAD ... +``` +### foxyproxy/10-redefine.yml + + +```yml +%YAML 1.2 +--- +version: 1.1 + +proxies: + + username: + redefine: true + mandatory: false + + password: + redefine: true + hidden: + jinja: |- + {% if not _.username %} + no username defined + {% endif %} + description: if username is not defined +... + ``` ### Let's generate the documentation ```console -foo@bar:~$ git switch --detach v1.1_105 +foo@bar:~$ git switch --detach v1.1_110 foo@bar:~$ rougail -m firefox/ -s Firefox -xn FoxyProxy -xd 0 foxyproxy/ --modes_level basic standard advanced -o doc ``` #### Variables for "Firefox" @@ -503,12 +528,12 @@ This family contains lists of variable blocks - HTTPS/SSL - SOCKS4 - SOCKS5 | -| **foxyproxy.proxies.username**
[`unix_user`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` *`mandatory`* *`disabled`* | Username.
**Mandatory**: if a password is set
**Disabled**: if type not in: +| **foxyproxy.proxies.username**
[`unix_user`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` *`disabled`* | Username.
**Disabled**: if type not in: - HTTP - HTTPS/SSL - SOCKS4 - SOCKS5 | -| **foxyproxy.proxies.password**
[`secret`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` *`disabled`* | Password.
**Disabled**: if type not in: +| **foxyproxy.proxies.password**
[`secret`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` *`hidden`* *`disabled`* | Password.
**Hidden**: if username is not defined
**Disabled**: if type not in: - HTTP - HTTPS/SSL - SOCKS4 @@ -520,44 +545,23 @@ This family contains lists of variable blocks ### Let's generate the changelog ```console -foo@bar:~$ git switch --detach v1.1_105 +foo@bar:~$ git switch --detach v1.1_110 foo@bar:~$ rougail -m firefox/ -s Firefox -xn FoxyProxy -xd 0 foxyproxy/ --modes_level basic standard advanced -o doc --doc.contents changelog ``` -#### New variables +#### Modified variables -| Variable                                                                                                                     | Description                                                                                                                  | -|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| **foxyproxy.proxies.address**
[`domainname`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` *`disabled`* | IP address, DNS name, server name.
**Validators**:
- the domain name can be a hostname
- the domain name can be an IP
**Default**: copy HTTP address if proxy is not "Manual"
**Disabled**: if type not in: +| Variable                                                                                                                          | Description                                                                                                                       | +|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| **foxyproxy.proxies.color**
[`regexp`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` `auto modified` | Color.
**Validator**: text based with regular expressions "^#(?:[0-9a-f]{3}){1,2}$"
**Default**: random color value | +| **foxyproxy.proxies.username**
~~`mandatory`~~ [`unix_user`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` *`disabled`* | Username.
**Mandatory**: ~~if a password is set~~
**Disabled**: if type not in: - HTTP - HTTPS/SSL - SOCKS4 -- SOCKS5 | -| **foxyproxy.proxies.port**
[`port`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` *`disabled`* | Port.
**Validators**:
- well-known ports (1 to 1023) are allowed
- registred ports (1024 to 49151) are allowed
- private ports (greater than 49152) are allowed
**Default**: copy HTTP port if proxy is not "Manual"
**Disabled**: if type not in: +- SOCKS5 | +| **foxyproxy.proxies.password**
[`secret`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` *`hidden`* *`disabled`* | Password.
**Hidden**: if username is not defined
**Disabled**: if type not in: - HTTP - HTTPS/SSL - SOCKS4 -- SOCKS5 | -| **foxyproxy.proxies.username**
[`unix_user`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` *`mandatory`* *`disabled`* | Username.
**Mandatory**: if a password is set
**Disabled**: if type not in: -- HTTP -- HTTPS/SSL -- SOCKS4 -- SOCKS5 | -| **foxyproxy.proxies.password**
[`secret`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` *`disabled`* | Password.
**Disabled**: if type not in: -- HTTP -- HTTPS/SSL -- SOCKS4 -- SOCKS5 | -| **foxyproxy.proxies.url**
[`web_address`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` *`disabled`* | URL.
**Validator**: the domain name in web address can be only a hostname
**Default**: copy HTTP address if proxy is "Auto"
**Disabled**: if type is not in: -- PAC URL -- WPAD | - -#### Modified variable - -| Variable                                                                                                                     | Description                                                                                                                  | -|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| **foxyproxy.proxies.color**
[`regexp`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` `auto modified` | Color.
**Validator**: text based with regular expressions "^#(?:[0-9a-f]{3}){1,2}$"
**Default**: random color value | +- SOCKS5 | - - -- [[tutorial v1.1_110] xxx](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_110/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_110~1..v1.1_110))