mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-06-03 10:50:20 +00:00
tor: Check if Hidden service is version 3
Check that the Hidden service hostname contains 56 bytes before the .onion. Helps: #2104 Tests: - With Hidden service enabled, v3 check is passed. - With Hidden service disabled, v3 check is skipped. Signed-off-by: James Valleroy <jvalleroy@mailbox.org> Reviewed-by: Sunil Mohan Adapa <sunil@medhas.org>
This commit is contained in:
parent
56adc7ae22
commit
f9e039b4cb
@ -159,6 +159,13 @@ class TorApp(app_module.App):
|
||||
results.append(
|
||||
diagnose_port_listening(int(ports['obfs4']), 'tcp6'))
|
||||
|
||||
if status['hs_enabled']:
|
||||
hs_hostname = status['hs_hostname'].split('.onion')[0]
|
||||
results.append([
|
||||
_('Hidden service is version 3'),
|
||||
'passed' if len(hs_hostname) == 56 else 'failed'
|
||||
])
|
||||
|
||||
results.append(_diagnose_url_via_tor('http://www.debian.org', '4'))
|
||||
results.append(_diagnose_url_via_tor('http://www.debian.org', '6'))
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user