[tutorial 104] xxx (config and doc)

This commit is contained in:
egarette@silique.fr 2024-11-02 14:59:05 +01:00
parent 8fb1a6c1e7
commit cd4da10a92
3 changed files with 125 additions and 57 deletions

132
README.md
View file

@ -1,9 +1,9 @@
- [Summary](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/branch/1.1/README.md)
- [[tutorial 102] xxx](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_102/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_102~1..v1.1_102))
- [[tutorial 103] xxx](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_103/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_103~1..v1.1_103))
# [tutorial 103] xxx
# [tutorial 104] xxx
[View the diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_103~1..v1.1_103)
[View the diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_104~1..v1.1_104)
## Screenshot
@ -255,6 +255,77 @@ proxies:
{%- endfor -%}
description: random color value
address:
description: IP address, DNS name, server name
type: domainname
params:
allow_ip: true
allow_without_dot: true
disabled: &needs_address
jinja: |
{% if _.type not in ['HTTP', 'HTTPS/SSL', 'SOCKS4', 'SOCKS5'] %}
disabled
{% endif %}
description: |
if type not in:
- HTTP
- HTTPS/SSL
- SOCKS4
- SOCKS5
default:
jinja: |
{% if firefox.manual.http_proxy.address is not propertyerror %}
{{ firefox.manual.http_proxy.address }}
{% endif %}
description: copy HTTP address if proxy is not "Manual"
port:
description: Port
type: port
default:
jinja: |
{% if firefox.manual.http_proxy.port is not propertyerror %}
{{ firefox.manual.http_proxy.port }}
{% endif %}
description: copy HTTP port if proxy is not "Manual"
disabled: *needs_address
username:
description: Username
type: unix_user
mandatory:
jinja: |
{% if _.password is not propertyerror and _.password %}
username is mandatory
{% endif %}
description: if a password is set
disabled: *needs_address
password:
description: Password
type: secret
mandatory: false
disabled: *needs_address
url:
description: URL
type: web_address
disabled:
jinja: |
{% if _.type not in ['PAC URL', 'WPAD'] %}
proxy does not need url
{% endif %}
description: |
if type is not in:
- PAC URL
- WPAD
default:
jinja: |
{% if firefox.auto is not propertyerror %}
{{ firefox.auto }}
{% endif %}
description: copy HTTP address if proxy is "Auto"
```
### Generated documentation
@ -329,11 +400,16 @@ This family builds families dynamically.
This family contains lists of variable blocks.
| Variable                                                                                                                | Description                                                                                                             |
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Variable                                                                                                                     | Description                                                                                                                  |
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| **foxyproxy.proxies.title**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `unique` `multiple` | Title or Description. |
| **foxyproxy.proxies.type**<br/>[`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` | Proxy Type.<br/>**Choices**: <br/>- HTTP<br/>- HTTPS/SSL<br/>- SOCKS4<br/>- SOCKS5<br/>- PAC URL<br/>- WPAD<br/>- System (use system settings)<br/>- Direct (no proxy) ← (default) |
| **foxyproxy.proxies.color**<br/>[`regexp`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` `auto modified` | Color.<br/>**Default**: random color value. |
| **foxyproxy.proxies.address**<br/>[`domainname`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` _`disabled`_ | IP address, DNS name, server name.<br/>**Validators**:<br/>- the domain name can be a hostname<br/>- the domain name can be an IP<br/>**Default**: copy HTTP address if proxy is not "Manual".<br/>**Disabled**: if type not in:<br/>- HTTP<br/>- HTTPS/SSL<br/>- SOCKS4<br/>- SOCKS5. |
| **foxyproxy.proxies.port**<br/>[`port`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` _`disabled`_ | Port.<br/>**Default**: copy HTTP port if proxy is not "Manual".<br/>**Disabled**: if type not in:<br/>- HTTP<br/>- HTTPS/SSL<br/>- SOCKS4<br/>- SOCKS5. |
| **foxyproxy.proxies.username**<br/>[`unix_user`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` _`mandatory`_ _`disabled`_ | Username.<br/>**Mandatory**: if a password is set.<br/>**Disabled**: if type not in:<br/>- HTTP<br/>- HTTPS/SSL<br/>- SOCKS4<br/>- SOCKS5. |
| **foxyproxy.proxies.password**<br/>[`secret`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` _`disabled`_ | Password.<br/>**Disabled**: if type not in:<br/>- HTTP<br/>- HTTPS/SSL<br/>- SOCKS4<br/>- SOCKS5. |
| **foxyproxy.proxies.url**<br/>[`web_address`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` _`disabled`_ | URL.<br/>**Default**: copy HTTP address if proxy is "Auto".<br/>**Disabled**: if type is not in:<br/>- PAC URL<br/>- WPAD. |
## User data
@ -387,24 +463,8 @@ foxyproxy:
foo@bar:~$ rougail -v 1.1 -m firefox/ -s Firefox -xn FoxyProxy -xd 0 foxyproxy/ --modes_level basic standard advanced -u file -ff config/02/config.yaml
```
<pre>🛑 ERRORS
<span style="color: #ff0000">┗━━ </span>unknown option "address" in optiondescription "foxyproxy.proxies" (Proxy configuration)
╭────────────────────────── Caption ──────────────────────────╮
│ Variable <span style="color: #ffd700">Default value</span>
<span style="color: #5c5cff">Undocumented variable</span> Modified value │
<span style="color: #ff0000">Undocumented but modified variable</span> (<span style="color: #00aa00">Original default value</span>) │
<span style="color: #ffaf00">Unmodifiable variable</span>
╰─────────────────────────────────────────────────────────────╯
Variables:
<span style="color: #5c5cff">┣━━ </span>📂 firefox
<span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 proxy_mode: <span style="color: #ffd700">No proxy</span>
<span style="color: #5c5cff"></span><span style="color: #5c5cff">┗━━ </span>📂 dns_over_https
<span style="color: #5c5cff"></span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📓 enable_dns_over_https: <span style="color: #ffd700">False</span>
<span style="color: #5c5cff">┗━━ </span>📂 foxyproxy
<span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📂 proxies
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📂 title
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📓 title: My company
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📓 type: HTTP (<span style="color: #00aa00">Direct (no proxy)</span>)
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📓 color: #66cc66
<span style="color: #ff0000">┣━━ </span>The following variables are mandatory but have no value:
<span style="color: #ff0000">┗━━ </span> - foxyproxy.proxies.port (Port)
</pre>
### Example 3
@ -440,9 +500,12 @@ foxyproxy:
foo@bar:~$ rougail -v 1.1 -m firefox/ -s Firefox -xn FoxyProxy -xd 0 foxyproxy/ --modes_level basic standard advanced -u file -ff config/03/config.yaml
```
<pre>🛑 ERRORS
<span style="color: #ff0000">┣━━ </span>unknown option "password" in optiondescription "foxyproxy.proxies" (Proxy configuration)
<span style="color: #ff0000">┣━━ </span>unknown option "username" in optiondescription "foxyproxy.proxies" (Proxy configuration)
<span style="color: #ff0000">┗━━ </span>unknown option "url" in optiondescription "foxyproxy.proxies" (Proxy configuration)
<span style="color: #ff0000">┣━━ </span>cannot access to option "foxyproxy.proxies.password" (Password) because has property "disabled"
<span style="color: #ff0000"></span>(disabled)
<span style="color: #ff0000">┣━━ </span>cannot access to option "foxyproxy.proxies.url" (URL) because has property "disabled" (proxy does not
<span style="color: #ff0000"></span>need url)
<span style="color: #ff0000">┗━━ </span>cannot access to option "foxyproxy.proxies.username" (Username) because has property "disabled"
<span style="color: #ff0000"> </span>(disabled)
╭────────────────────────── Caption ──────────────────────────╮
│ Variable <span style="color: #ffd700">Default value</span>
<span style="color: #5c5cff">Undocumented variable</span> Modified value │
@ -474,16 +537,25 @@ Variables:
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📂 title
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 title: My company
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 type: HTTP (<span style="color: #00aa00">Direct (no proxy)</span>)
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┗━━ </span>📓 color: #66cc66
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 color: #66cc66
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 address: <span style="color: #ffd700">http.proxy.net</span>
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 port: <span style="color: #ffd700">8080</span>
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 username: None
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┗━━ </span>📓 password: None
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📂 title
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 title: An other company
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 type: SOCKS5 (<span style="color: #00aa00">Direct (no proxy)</span>)
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┗━━ </span>📓 color: #cc66cc
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 color: #cc66cc
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 address: <span style="color: #ffd700">http.proxy.net</span>
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 port: <span style="color: #ffd700">8080</span>
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 username: my_user
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┗━━ </span>📓 password: **********
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📂 title
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📓 title: WPAD
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📓 type: WPAD (<span style="color: #00aa00">Direct (no proxy)</span>)
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📓 color: #1166cc
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📓 color: #1166cc
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📓 url: http://wpad.proxy.net/wpad.dat
</pre>
- [[tutorial 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 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))

View file

@ -1,20 +1,4 @@
<pre>🛑 ERRORS
<span style="color: #ff0000">┗━━ </span>unknown option "address" in optiondescription "foxyproxy.proxies" (Proxy configuration)
╭────────────────────────── Caption ──────────────────────────╮
│ Variable <span style="color: #ffd700">Default value</span>
<span style="color: #5c5cff">Undocumented variable</span> Modified value │
<span style="color: #ff0000">Undocumented but modified variable</span> (<span style="color: #00aa00">Original default value</span>) │
<span style="color: #ffaf00">Unmodifiable variable</span>
╰─────────────────────────────────────────────────────────────╯
Variables:
<span style="color: #5c5cff">┣━━ </span>📂 firefox
<span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 proxy_mode: <span style="color: #ffd700">No proxy</span>
<span style="color: #5c5cff"></span><span style="color: #5c5cff">┗━━ </span>📂 dns_over_https
<span style="color: #5c5cff"></span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📓 enable_dns_over_https: <span style="color: #ffd700">False</span>
<span style="color: #5c5cff">┗━━ </span>📂 foxyproxy
<span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📂 proxies
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📂 title
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📓 title: My company
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📓 type: HTTP (<span style="color: #00aa00">Direct (no proxy)</span>)
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📓 color: #66cc66
<span style="color: #ff0000">┣━━ </span>The following variables are mandatory but have no value:
<span style="color: #ff0000">┗━━ </span> - foxyproxy.proxies.port (Port)
</pre>

View file

@ -1,7 +1,10 @@
<pre>🛑 ERRORS
<span style="color: #ff0000">┣━━ </span>unknown option "password" in optiondescription "foxyproxy.proxies" (Proxy configuration)
<span style="color: #ff0000">┣━━ </span>unknown option "username" in optiondescription "foxyproxy.proxies" (Proxy configuration)
<span style="color: #ff0000">┗━━ </span>unknown option "url" in optiondescription "foxyproxy.proxies" (Proxy configuration)
<span style="color: #ff0000">┣━━ </span>cannot access to option "foxyproxy.proxies.password" (Password) because has property "disabled"
<span style="color: #ff0000"></span>(disabled)
<span style="color: #ff0000">┣━━ </span>cannot access to option "foxyproxy.proxies.url" (URL) because has property "disabled" (proxy does not
<span style="color: #ff0000"></span>need url)
<span style="color: #ff0000">┗━━ </span>cannot access to option "foxyproxy.proxies.username" (Username) because has property "disabled"
<span style="color: #ff0000"> </span>(disabled)
╭────────────────────────── Caption ──────────────────────────╮
│ Variable <span style="color: #ffd700">Default value</span>
<span style="color: #5c5cff">Undocumented variable</span> Modified value │
@ -33,13 +36,22 @@ Variables:
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📂 title
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 title: My company
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 type: HTTP (<span style="color: #00aa00">Direct (no proxy)</span>)
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┗━━ </span>📓 color: #66cc66
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 color: #66cc66
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 address: <span style="color: #ffd700">http.proxy.net</span>
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 port: <span style="color: #ffd700">8080</span>
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 username: None
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┗━━ </span>📓 password: None
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📂 title
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 title: An other company
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 type: SOCKS5 (<span style="color: #00aa00">Direct (no proxy)</span>)
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┗━━ </span>📓 color: #cc66cc
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 color: #cc66cc
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 address: <span style="color: #ffd700">http.proxy.net</span>
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 port: <span style="color: #ffd700">8080</span>
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┣━━ </span>📓 username: my_user
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"></span><span style="color: #5c5cff">┗━━ </span>📓 password: **********
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📂 title
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📓 title: WPAD
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📓 type: WPAD (<span style="color: #00aa00">Direct (no proxy)</span>)
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📓 color: #1166cc
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┣━━ </span>📓 color: #1166cc
<span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff"> </span><span style="color: #5c5cff">┗━━ </span>📓 url: http://wpad.proxy.net/wpad.dat
</pre>