From d54ba9b324a77b59cd847adcf2e903c75e322b00 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Tue, 30 Mar 2021 16:03:50 -0400 Subject: [PATCH] Change url used for authentication to magicBox.cgi?action=getDeviceType --- scripts/ZoneMinder/lib/ZoneMinder/Control/Amcrest_HTTP.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/ZoneMinder/lib/ZoneMinder/Control/Amcrest_HTTP.pm b/scripts/ZoneMinder/lib/ZoneMinder/Control/Amcrest_HTTP.pm index 59e4f7511..df7bed42c 100644 --- a/scripts/ZoneMinder/lib/ZoneMinder/Control/Amcrest_HTTP.pm +++ b/scripts/ZoneMinder/lib/ZoneMinder/Control/Amcrest_HTTP.pm @@ -75,7 +75,7 @@ sub open { } # Detect REALM, has to be /cgi-bin/ptz.cgi because just / accepts no auth - my $res = $self->{ua}->get($$self{base_url}.'cgi-bin/ptz.cgi'); + my $res = $self->{ua}->get($$self{base_url}.'cgi-bin/magicBox.cgi?action=getDeviceType'); if ( $res->is_success ) { $self->{state} = 'open'; @@ -121,7 +121,7 @@ sub open { Debug('No headers line'); } # end if headers } else { - Error("Failed to get $$self{base_url}cgi-bin/ptz.cgi ".$res->status_line()); + Error("Failed to get $$self{base_url}cgi-bin/magicBox.cgi?action=getDeviceType ".$res->status_line()); } # end if $res->status_line() eq '401 Unauthorized'