Authorized known instances

merge-requests/30/head
Bob Mottram 2024-11-16 18:08:25 +00:00
parent 6f704b5331
commit ccdfbd2059
2 changed files with 3 additions and 2 deletions

View File

@ -2263,7 +2263,7 @@ def daemon_http_get(self) -> None:
self.server.debug)
return
if self.path == '/knowninstances':
if self.path.endswith('/knowninstances'):
if not authorized:
http_403(self)
return

View File

@ -352,7 +352,8 @@ def get_left_column_content(base_dir: str, nickname: str, domain_full: str,
'<p class="login-text"><a href="/about">' + \
translate['About this Instance'] + '</a></p>'
html_str += \
'<p class="login-text"><a href="/knowninstances">' + \
'<p class="login-text"><a href="/users/' + \
nickname + '/knowninstances">' + \
translate['Epicyon Instances'] + '</a></p>'
html_str += \
'<p class="login-text"><a href="/manual">' + \