How can I add HikVision camera (problem with CORS)?
Moderator: leecollings
-
- Posts: 269
- Joined: Thursday 26 March 2015 10:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Poland
- Contact:
How can I add HikVision camera (problem with CORS)?
Hi
In postman i can call
http://IP:PORT/ISAPI/Streaming/channels/101/picture
with basic or digest auth, and i see a image.
In Domoticz I set this data, and when i click "Test connection" i don't see picture.
In network status i see "(blocked:origin)"
How can I fix it?
In postman i can call
http://IP:PORT/ISAPI/Streaming/channels/101/picture
with basic or digest auth, and i see a image.
In Domoticz I set this data, and when i click "Test connection" i don't see picture.
In network status i see "(blocked:origin)"
How can I fix it?
- habahabahaba
- Posts: 212
- Joined: Saturday 18 March 2023 14:44
- Target OS: Windows
- Domoticz version: 2024.4
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
I have 3 hikvision cameras. All works fine in Dz (etc. in Dzvents, 'http://<user>:<pass>@192.168.0.85/ISAPI ... 01/picture' - for taking picture)
May be Port number, user, password? https instead of http?
May be Port number, user, password? https instead of http?
-
- Posts: 269
- Joined: Thursday 26 March 2015 10:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Poland
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
I try set parameters in configuration->Cameras
I am providing exactly the same ones as via postman.
But error is weird. Its not something like 401,404,405 etc. Its "blocked origin".
I am providing exactly the same ones as via postman.
But error is weird. Its not something like 401,404,405 etc. Its "blocked origin".
- waltervl
- Posts: 5378
- Joined: Monday 28 January 2019 18:48
- Target OS: Linux
- Domoticz version: 2024.7
- Location: NL
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
Is the ImageURL correct? should be: /ISAPI/Streaming/channels/101/picture
Perhaps strange characters in userID or password?
Perhaps strange characters in userID or password?
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
-
- Posts: 269
- Joined: Thursday 26 March 2015 10:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Poland
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
Yes - url corrected - like in first post.
Zero weird characters in user/password.
Zero weird characters in user/password.
- waltervl
- Posts: 5378
- Joined: Monday 28 January 2019 18:48
- Target OS: Linux
- Domoticz version: 2024.7
- Location: NL
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
Did you try ImageURL without the first slash?
ISAPI/Streaming/channels/101/picture
ISAPI/Streaming/channels/101/picture
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
-
- Posts: 269
- Joined: Thursday 26 March 2015 10:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Poland
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
I can set anything, and i always see in network:
picture (blocked:origin)
This is problem with CORS or something like that (I think).
picture (blocked:origin)
This is problem with CORS or something like that (I think).
- habahabahaba
- Posts: 212
- Joined: Saturday 18 March 2023 14:44
- Target OS: Windows
- Domoticz version: 2024.4
- Contact:
-
- Posts: 269
- Joined: Thursday 26 March 2015 10:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Poland
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
I can change anything (ip, user, path etc) and i have always this same error in network.
In Postman i call http://192.168.1.xx:80/ISAPI/Streaming/ ... 01/picture and I can get picture.
In Postman i call http://192.168.1.xx:80/ISAPI/Streaming/ ... 01/picture and I can get picture.
- Attachments
-
- screenshot
- Capture.PNG (46.94 KiB) Viewed 2431 times
- habahabahaba
- Posts: 212
- Joined: Saturday 18 March 2023 14:44
- Target OS: Windows
- Domoticz version: 2024.4
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
May be try to update the firmware of camera?
And did you try to get image from dzvent-script?
And did you try to get image from dzvent-script?
-
- Posts: 269
- Joined: Thursday 26 March 2015 10:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Poland
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
This is problem with routing/proxy or something like that i think
Camera have the newest firmware.
I don't use LUA
Camera have the newest firmware.
I don't use LUA

- waltervl
- Posts: 5378
- Joined: Monday 28 January 2019 18:48
- Target OS: Linux
- Domoticz version: 2024.7
- Location: NL
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
This preview is sometimes not working on this page. Perhaps check the normal functionality. Eg add a trigger switch and have the screenshot sent by email.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
-
- Posts: 104
- Joined: Saturday 25 November 2017 17:18
- Target OS: Raspberry Pi / ODroid
- Domoticz version: v3.8153
- Location: Czech Rep.
- Contact:
Re: How can I add HikVision camera (problem with CORS)?
First - I see your address "/channels/1/pic..." and for me works "/channels/101/pic..."
Second - Hikvision in manual recommends using strong passwords, but beware, you cannot use some characters in the http address.
For example my own painful experience when testing stream with VLC. My password contains a capital letter and a + character and VLC converted everything to lowercase letters before sending the address and removed + character. Therefore, I recommend a simple username and password for testing.
Second - Hikvision in manual recommends using strong passwords, but beware, you cannot use some characters in the http address.
For example my own painful experience when testing stream with VLC. My password contains a capital letter and a + character and VLC converted everything to lowercase letters before sending the address and removed + character. Therefore, I recommend a simple username and password for testing.
RPi2 Domoticz v 4.10717
10 x Sonoff Basic - ESPeasy
1 x Wemos D1 - ESPeasy
1 x Shelly Plus Plug S
1 x Sonoff S26 - ESPeasy
1 x Shelly 1
1 x MySensors HC-SR04
1 x MySenosrs wifi gateway
1 x RFLink
4x Cam IPC-T240H
10 x Sonoff Basic - ESPeasy
1 x Wemos D1 - ESPeasy
1 x Shelly Plus Plug S
1 x Sonoff S26 - ESPeasy
1 x Shelly 1
1 x MySensors HC-SR04
1 x MySenosrs wifi gateway
1 x RFLink
4x Cam IPC-T240H
Who is online
Users browsing this forum: No registered users and 1 guest