From 16b15ea08909690f2752db5d0fa26402b2f3f298 Mon Sep 17 00:00:00 2001 From: Richard Hansen Date: Tue, 23 Jul 2024 01:42:06 -0400 Subject: [PATCH] porkbun: Remove headers from HTTP response before processing --- ddclient.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ddclient.in b/ddclient.in index 452ba41..7300c08 100755 --- a/ddclient.in +++ b/ddclient.in @@ -6808,7 +6808,8 @@ sub nic_porkbun_update { failed("updating %s: failed (%s)", $h, $reply); next; } - $reply =~ qr/{(?:[^{}]*|(?R))*}/mp; + (my $body = $reply) =~ s/^.*?\n\n//s; + $body =~ qr/{(?:[^{}]*|(?R))*}/mp; my $response = eval { decode_json(${^MATCH}) }; if (!defined($response)) { failed("%s -- Unexpected service response.", $h);