Merge pull request #920 from davotoula/915-NIP05-verification-follows-redirects-against-specification

Set redirects to false for httpclient used during nip05
This commit is contained in:
Vitor Pamplona 2024-06-15 09:45:49 -04:00 committed by GitHub
commit 21c397b5e0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -64,8 +64,8 @@ class Nip05NostrAddressVerifier() {
.header("User-Agent", "Amethyst/${BuildConfig.VERSION_NAME}")
.url(url)
.build()
HttpClientManager.getHttpClient()
// Fetchers MUST ignore any HTTP redirects given by the /.well-known/nostr.json endpoint.
HttpClientManager.getHttpClient().newBuilder().followRedirects(false).build()
.newCall(request)
.enqueue(
object : Callback {