mirror of
https://github.com/yattee/yattee.git
synced 2026-05-12 02:17:46 +00:00
Allow HTTP Basic Auth credentials for any remote-server instance type
EditSourceView now exposes the basic-auth username/password fields for every instance type (Invidious, Piped, PeerTube, Yattee Server), keeping the existing required-credentials UI for Yattee Server and adding an optional section for the others. Credentials are loaded and persisted via BasicAuthCredentialsManager regardless of type, and clearing both fields deletes stored credentials for non-Yattee types. AddRemoteServerView gains a new basicAuthRequired UI state: when instance detection hits a 401 (the entire instance is behind a reverse proxy), the view reveals username/password fields and a Retry Detection button. The retry calls the detector with the credentials injected as an Authorization header; on success the form transitions into the normal detected state with the credentials pre-populated. A repeat 401 shows an inline "invalid credentials" message instead of restarting the flow. For non-Yattee types, any credentials entered during the flow are persisted alongside the new instance.
This commit is contained in:
@@ -14560,6 +14560,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"sources.retryDetection" : {
|
||||
"comment" : "Button to retry instance detection after providing HTTP Basic Auth credentials",
|
||||
"localizations" : {
|
||||
"en" : {
|
||||
"stringUnit" : {
|
||||
"state" : "translated",
|
||||
"value" : "Retry Detection"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"sources.editSource" : {
|
||||
"comment" : "Title for edit source view",
|
||||
"localizations" : {
|
||||
@@ -15011,6 +15022,28 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"sources.footer.basicAuth" : {
|
||||
"comment" : "Footer text explaining optional HTTP Basic Auth credentials for instances behind a reverse proxy",
|
||||
"localizations" : {
|
||||
"en" : {
|
||||
"stringUnit" : {
|
||||
"state" : "translated",
|
||||
"value" : "Optional. Provide a username and password if this instance sits behind a reverse proxy that requires HTTP Basic Auth."
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"sources.footer.basicAuthRequired" : {
|
||||
"comment" : "Footer text shown when the instance is behind HTTP Basic Auth and credentials are required to detect it",
|
||||
"localizations" : {
|
||||
"en" : {
|
||||
"stringUnit" : {
|
||||
"state" : "translated",
|
||||
"value" : "This server is behind HTTP Basic Auth. Enter the username and password to continue."
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"sources.footer.yatteeServerAuth" : {
|
||||
"comment" : "Footer text explaining Yattee Server authentication",
|
||||
"localizations" : {
|
||||
@@ -15055,6 +15088,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"sources.header.basicAuth" : {
|
||||
"comment" : "Section header for HTTP Basic Auth credentials",
|
||||
"localizations" : {
|
||||
"en" : {
|
||||
"stringUnit" : {
|
||||
"state" : "translated",
|
||||
"value" : "HTTP Basic Authentication"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"sources.header.displayName" : {
|
||||
"comment" : "Section header for display name",
|
||||
"localizations" : {
|
||||
|
||||
Reference in New Issue
Block a user