Improved accounts_help and outbound_proxies_help strings

Added wss to account's transport protocols
This commit is contained in:
Juha Heinanen
2026-08-06 18:19:05 +03:00
parent be267c4afa
commit cd2a9d86f6
3 changed files with 24 additions and 21 deletions

View File

@ -249,8 +249,8 @@ object Utils {
fun checkAor(aor: String): Boolean {
if (!checkSipUri(aor)) return false
val params = uriParams(aor)
return params.isEmpty() ||
((params.size == 1) && params[0] in arrayOf("transport=udp", "transport=tcp", "transport=tls"))
val transports = arrayOf("transport=udp", "transport=tcp", "transport=tls", "transport=wss")
return params.isEmpty() || ((params.size == 1) && params[0] in transports)
}
private fun checkTransport(transport: String, transports: Set<String>): Boolean {

View File

@ -144,13 +144,15 @@
lähettää molemmille välityspalvelimille ja muut sanomat yhdelle
toiminnassa olevalle välityspalvelimelle. Jos välityspalvelimia ei
ole annettu, SIP-sanomat lähetetään palvelimelle, mikä selviää
kohteen domainille tehtävien NAPTR/SRV/Animipalvelukyselyiden perusteella.
Jos välityspalvelimen osoite SIP
kohteen domainille tehtävien NAPTR/SRV/A nimipalvelukyselyiden perusteella.
SIP URI on muotoa sip:&lt;host&gt;[:&lt;port&gt;][;transport=udp|tcp|tls|wss].
Jos porttia ei ole annettu ja transport on annettu, portin oletusarvo on 5060 (udp, tcp),
5061 (tls) tai 443 (wss). Jos välityspalvelimen osoite SIP
URI:ssa on IPv6-osoite, osoite pitää kirjoittaa sulkujen [] sisään.
\nEsimerkkejä:
\n • sip:example.com:5061;transport=tls
\n • sip:example.com:6601transport=tls
\n • sip:[2001:67c:223:777::10];transport=tcp
\n • sip:192.168.43.50:443;transport=wss
\n • sip:192.168.43.50:4430;transport=wss
</string>
<string name="sip_uri_of_proxy_server">Välityspalvelimen SIP URI</string>
<string name="sip_uri_of_another_proxy_server">Toisen
@ -256,13 +258,13 @@
<string name="accounts">Tilit</string>
<string name="new_account">Uuden tilin SIP URI</string>
<string name="accounts_help">Uuden tilin SIP URI muotoa
&lt;käyttäjä&gt;@&lt;domain&gt;[:&lt;portti&gt;][;transport=udp|tcp|tls].
&lt;käyttäjä&gt;@&lt;domain&gt;[:&lt;portti&gt;][;transport=udp|tcp|tls|wss].
Jos &lt;portti&gt; on annettu, mutta protokollaa ei ole annettu, protokolla on udp.
Jos &lt;portti&gt; ei ole annettu, mutta protokolla on annettu, portti on joko 5060 tai 5061 (tls).
Jos kumpaakaan ei ole annettu eikä välityspalvelinta ole määritelty, tilin mahdollinen
Jos &lt;portti&gt; ei ole annettu, mutta protokolla on annettu, portti on joko 5060 (udp, tcp), 5061 (tls) tai
443 (wss). Jos kumpaakaan ei ole annettu eikä välityspalvelinta ole määritelty, tilin mahdollinen
rekisteröintipalvelin päätellään pelkästään domainin DNS-informaation perusteella.
</string>
<string name="invalid_aor">Virheellinen käyttäjä@domain[:portti][;transport=udp|tcp|tls] \'%1$s\'
<string name="invalid_aor">Virheellinen käyttäjä@domain[:portti][;transport=udp|tcp|tls|wss] \'%1$s\'
</string>
<string name="account_exists">Tili \'%1$s\' on jo olemassa.</string>
<string name="account_allocation_failure">Uuden tilin luonti epäonnistui.</string>

View File

@ -147,12 +147,14 @@
<string name="outbound_proxies_help">SIP URI of one or two proxies that must be used when sending requests.
If two is given, REGISTER requests are sent to both and other requests are sent to
one that responds. If no outbound proxy is given, requests are sent based on
DNS NAPTR/SRV/A record lookup of callee URI hostpart. If hostpart of SIP URI is an IPv6
address, the address must be written inside brackets [].
DNS NAPTR/SRV/A record lookup of request URI hostpart. SIP URI is of the form
sip:&lt;host&gt;[:&lt;port&gt;][;transport=udp|tcp|tls|wss].
If &lt;port&gt; is not given and transport protocol is given, &lt;port&gt; defaults to 5060 (udp, tcp), 5061 (tls),
or 443 (wss). If &lt;host&gt; is an IPv6 address, the address must be written inside brackets [].
\nExamples:
\n • sip:example.com:5061;transport=tls
\n • sip:example.com:6601;transport=tls
\n • sip:[2001:67c:223:777::10];transport=tcp
\n • sip:192.168.43.50:443;transport=wss
\n • sip:192.168.43.50:4430;transport=wss
</string>
<string name="sip_uri_of_proxy_server">SIP URI of Proxy Server</string>
<string name="sip_uri_of_another_proxy_server">SIP URI of another Proxy Server</string>
@ -174,7 +176,7 @@
Establishment, RFC 5245).
</string>
<string name="stun_server">STUN/TURN Server</string>
<string name="stun_server_help">A STUN/TURN Server URI of form scheme:host[:port][?transport=udp|tcp],
<string name="stun_server_help">A STUN/TURN Server URI of form scheme:host[:port][;transport=udp|tcp],
where scheme is \'stun\', \'stuns\', \'turn\', or \'turns\'. Factory default STUN Server
for STUN and ICE protocols is \'stun:stun.l.google.com:19302\' pointing to public Google
STUN server. There is no factory default TURN server.
@ -248,14 +250,13 @@
<!-- Accounts Activity -->
<string name="accounts">Accounts</string>
<string name="new_account">SIP URI of New Account</string>
<string name="accounts_help">SIP URI of new account of form
&lt;user&gt;@&lt;domain&gt;[:&lt;port&gt;][;transport=udp|tcp|tls].
If &lt;port&gt; is given and transport protocol is not given, transport protocol defaults to UDP.
If &lt;port&gt; is not given and transport protocol is given, &lt;port&gt; defaults to 5060 or 5061 (TLS).
If neither is given and no outbound proxy is specified, account\'s registrar (if any) is
<string name="accounts_help">SIP URI of new account of form &lt;user&gt;@&lt;domain&gt;[:&lt;port&gt;][;transport=udp|tcp|tls|wss].
If &lt;port&gt; is given and transport protocol is not given, transport protocol defaults to udp.
If &lt;port&gt; is not given and transport protocol is given, &lt;port&gt; defaults to 5060 (udp, tcp), 5061 (tls),
or 443 (wss). If neither is given and no outbound proxy is specified, account\'s registrar (if any) is
determined solely based on domain\'s DNS information.
</string>
<string name="invalid_aor">Invalid user@domain[:port][;transport=udp|tcp|tls] \'%1$s\'</string>
<string name="invalid_aor">Invalid user@domain[:port][;transport=udp|tcp|tls|wss] \'%1$s\'</string>
<string name="account_exists">Account \'%1$s\' already exists.</string>
<string name="account_allocation_failure">Failed to allocate new account.</string>
<string name="encrypt_password">Encrypt Password</string>