- May 12, 2016
- 4,582
- 3,929
Browser plugins are going the way of the dodo so how can I view/setup my cameras?
Good news, newer cameras and firmware updates for some cameras and NVRs no longer depend on Dahua's plugins. Unfortunately some now depend on Adobe Flash Player, which Adobe plans to kill in 2020. If your camera depends on flash, use a browser like Google Chrome that has an always up-to-date version of flash built in. Firmware dated 8/2018 or newer may work without plugins or with flash. If you've got a newer device or a recent firmware update, try your favorite browser then try another browser to see what works before you go too far down the rabbit hole of other options for making the dahua plugins work.
If you use Blue Iris or other VMS software with an HTML5 interface 95% of the time, you'll be using that software and won't have to worry about what the cameras support. In this scenario, you only need to access the cameras directly to occasionally change some settings on the cameras
Be careful if you attempt to update the firmware on your devices. While firmware updates generally fix bugs and sometimes add features, sometimes features are removed or new bugs are added. Don't just update all of your cameras to the latest firmware, search out information regarding that fw version and test it on a single camera for at least a few weeks before you deploy it to multiple cameras! Be especially careful when updating the firmware on large PTZ cameras!
Browser plug-ins are generally awfully coded monstrosities full of security vulnerabilities, so it's a good thing most browsers are dropping support. If you keep a browser with plug-in support, I suggest only using it for your cameras or only allowing plugins to run on the pages for your cameras.
If you're having problems, please include the camera model, firmware versions, browser version, and if applicable the plugin version in your post.
Some recent threads discussing this in more detail:
Dahua camera web interface - OS support, plugins in 2018
Safari plugin for Dahua IPCs.
Dahua Web plugin has stopped working in Firefox
View your cameras that use plugins on windows using:
I use a mac, I think different:
Troubleshooting Plug-in Issues
BUT I WANT SOMETHING THAT DOESN'T REQUIRE A PLUGIN AT ALL!
BUT I WANT SOMETHING DIFFERENT!
But I want a way to quickly view my camera in a browser that doesn't support plugins anymore!
Good news, newer cameras and firmware updates for some cameras and NVRs no longer depend on Dahua's plugins. Unfortunately some now depend on Adobe Flash Player, which Adobe plans to kill in 2020. If your camera depends on flash, use a browser like Google Chrome that has an always up-to-date version of flash built in. Firmware dated 8/2018 or newer may work without plugins or with flash. If you've got a newer device or a recent firmware update, try your favorite browser then try another browser to see what works before you go too far down the rabbit hole of other options for making the dahua plugins work.
If you use Blue Iris or other VMS software with an HTML5 interface 95% of the time, you'll be using that software and won't have to worry about what the cameras support. In this scenario, you only need to access the cameras directly to occasionally change some settings on the cameras
Be careful if you attempt to update the firmware on your devices. While firmware updates generally fix bugs and sometimes add features, sometimes features are removed or new bugs are added. Don't just update all of your cameras to the latest firmware, search out information regarding that fw version and test it on a single camera for at least a few weeks before you deploy it to multiple cameras! Be especially careful when updating the firmware on large PTZ cameras!
Browser plug-ins are generally awfully coded monstrosities full of security vulnerabilities, so it's a good thing most browsers are dropping support. If you keep a browser with plug-in support, I suggest only using it for your cameras or only allowing plugins to run on the pages for your cameras.
If you're having problems, please include the camera model, firmware versions, browser version, and if applicable the plugin version in your post.
Some recent threads discussing this in more detail:
Dahua camera web interface - OS support, plugins in 2018
Safari plugin for Dahua IPCs.
Dahua Web plugin has stopped working in Firefox
View your cameras that use plugins on windows using:
- Internet Explorer 11
- Pale Moon 32-bit (you need 32-bit because the plugins are 32-bit)
- If pale moon gives you problems try other browsers you've never heard of like Basilisk (pale moon fork) and Midori that still support plugins
- Use The chrome NACL Web Plug-in chrome app
- Google plans to kill these native client chrome apps too, but there might be a fork of chromium that maintains support... time will tell.
- How do I use this?
- Go to chrome:/apps
- Click NACL Web Plug-in
- A new window will appear that looks a little different, load your camera / nvr's webpage
- It's generally a bit awful and prone to memory leaks.
- SmartPSS - you may have some issues if your text scaling is set to something other than 100%
- On linux, your best option that doesn't require a VM or WINE is to use Google Chrome and the NACL Web Plug-in chrome app (see windows section). I think this works in linux, but haven't tested it.
- Open the video stream in VLC or similar software
- Use VMS software that works in linux like veyesys | Video Management Platform
- You may want to try running SmartPSS in WINE
I use a mac, I think different:
- It's official, Safari 12 is out and has dropped plugin support.
- Safari 11 still supports browser plugins, but you may have to whitelist the plugin.
- On a mac plugins are generally stored in ~/Library/Internet Plugins or /Library/Internet Plugins to find these folders you'll need to use the Go menu or hit command-shift-g
- Safari is supposed to drop plugin support this year
- Your cameras must be set to use H.264 codecs not H.265, smart codec must be off
- Firefox ESR 52 can be made to work with plugins. oddly, yes the 64 bit version works. Disable automatic updates!
- You might have to change a setting in about:config
- I recommend you rename the Firefox ESR app so you can tell it apart from the regular version, renaming it Firefox ESR.app instead of Firefox.app would be a good choice. This way you can still use the current version of firefox if you want, but probably not at the same time without some extra effort. You also could run into some profile compatibility issues if you're running different versions of firefox, there is a workaround but it's a little messy.
- the chrome NACL plugin app works (see windows section above)
- Use SmartPSS
Troubleshooting Plug-in Issues
Start by going to
this will make most browsers show information about plugins that are installed.
here's the dahua plugin in palemoon:
Different devices (cameras / nvrs) and different firmware versions often require different versions of the plugins. This can get pretty messy.
Always try simple things like quitting and reopening the browser or rebooting your computer.
Code:
about:plugins
here's the dahua plugin in palemoon:
Different devices (cameras / nvrs) and different firmware versions often require different versions of the plugins. This can get pretty messy.
Always try simple things like quitting and reopening the browser or rebooting your computer.
BUT I WANT SOMETHING THAT DOESN'T REQUIRE A PLUGIN AT ALL!
Well, you can use Dahua's Smart PSS software. I works pretty well but does have a few bugs.
you can get it for Mac OS X and Windows here: Dahua Wiki
Some VMS software you can use to record your cameras can re-stream or transcode the stream to a format like HLS which modern web browsers support. Blue Iris can do this using the UI3 webserver. There are even some open source vms that can do this.
HLS typically adds about a 1 second delay.
You can also view the video stream using software like VLC or TinyCam (android) that can view the RTSP stream.
The stream address is formatted like this:
More information can be found in the HTTP API Documentation
To view a camera in VLC choose "Open Network Stream" in the media menu. Then enter your stream URL. If VLC gives you any trouble click "show more options" and set caching to something like 200-500 ms which will add a slight delay to the video but will fix most issues.
you can get it for Mac OS X and Windows here: Dahua Wiki
Some VMS software you can use to record your cameras can re-stream or transcode the stream to a format like HLS which modern web browsers support. Blue Iris can do this using the UI3 webserver. There are even some open source vms that can do this.
HLS typically adds about a 1 second delay.
You can also view the video stream using software like VLC or TinyCam (android) that can view the RTSP stream.
The stream address is formatted like this:
Code:
http://192.168.1.108/cgi-bin/realmonitor.cgi?action=getStream&channel=1&subtype=0
Substitute your camera's ip address
Change the channel number to view other cameras on an NVR
Change the subtype to switch between substreams. 0 = main, 1 = sub stream 1, 2 = sub stream 2.
You can add user:password@ to the beginning of the stream URL right after http:// if desired
NOTE: Newer firmware default to using digest authentication which may not be compatible with some software.
Your camera may have the option to change the type of authentication used for the rtsp stream.
To view a camera in VLC choose "Open Network Stream" in the media menu. Then enter your stream URL. If VLC gives you any trouble click "show more options" and set caching to something like 200-500 ms which will add a slight delay to the video but will fix most issues.
BUT I WANT SOMETHING DIFFERENT!
Well, the good news is Dahua appears to be working on HLS video support.
The bad news is it will probably be a while and will likely find its way to new products first if it makes it to the old ones at all.
The bad news is it will probably be a while and will likely find its way to new products first if it makes it to the old ones at all.
But I want a way to quickly view my camera in a browser that doesn't support plugins anymore!
Good news, there's an easy way to do this too using a bookmarklet. I wrote two simple bookmarklets that provide a simple fallback you can use if your browser doesn't support plugins. They are very simple, one displays a snapshot that reloads if you click it and the other displays an mjpg feed.
Limitations:
What's a bookmarlet? Bookmarlets are bookmarks that contain javascript instead of a link to a web page and modify the current page. They can be extremely useful. You can use them to do things like apply a dark theme to a website, reformat a website for easier printing, autofill a TPS report, generate a random password, or in this case display your cameras without plug-ins. More info here: Use bookmarklets to quickly perform common web page tasks | Firefox Help
To create a bookmarlet, make a new bookmark then edit the location and name of the bookmarlet. In chrome, copy the java script code, right click on your bookmark bar and choose add page. Then edit the name, keep it short, paste in the code from one of the code blocks below and save.
MJPG Bookmarlet:
Enable substream 2 and set it to mjpg 720p in order to use this. The video quality of MJPEG isn't as good as the normal RTSP stream.
Didn't work? You have to enable substream 2 and set it to mjpeg as directed. Not all cameras support 2 substreams and some only support mjpg at lower resolution (which still works, it just looks worse). Modify the code if required (eg. change subtype=2 to subtype=1 and you'll get substream 1).
Snapshot Bookmarlet:
Display a snapshot using this code, click the image to reload the snapshot. This one's a little uglier to read as it contains % encoded characters
Dahua should really implement something like this when plugins fail to load. These bookmarklets are pretty simple but might need some modification for your specific use case. You could also convert this to a userscript to make it run automatically.
How do I use the bookmarlet after I've created it?
Simply load the camera's page then click the bookmarklet. The snapshot one adds a cache busting timestamp to the url and reloads the snapshot when you click the image.
hikvision
Limitations:
- You can't define IVS or motion detection rules
- No audio
- No playback of recordings, live view only
- Can't easily display multiple cameras (not very useful on NVRs)
- Browser snapshot and record buttons don't work
- Can't make the mjpeg or snapshot full screen at this point
- Lower quality than using SmartPSS or VLC
- Lots of other things I forgot to mention.
What's a bookmarlet? Bookmarlets are bookmarks that contain javascript instead of a link to a web page and modify the current page. They can be extremely useful. You can use them to do things like apply a dark theme to a website, reformat a website for easier printing, autofill a TPS report, generate a random password, or in this case display your cameras without plug-ins. More info here: Use bookmarklets to quickly perform common web page tasks | Firefox Help
To create a bookmarlet, make a new bookmark then edit the location and name of the bookmarlet. In chrome, copy the java script code, right click on your bookmark bar and choose add page. Then edit the name, keep it short, paste in the code from one of the code blocks below and save.
MJPG Bookmarlet:
Enable substream 2 and set it to mjpg 720p in order to use this. The video quality of MJPEG isn't as good as the normal RTSP stream.
Code:
javascript:(document.getElementById("video").style.background = "url('cgi-bin/mjpg/video.cgi?channel=1&subtype=2') 50% 50% / contain no-repeat rgb(0, 0, 0)")();
Snapshot Bookmarlet:
Display a snapshot using this code, click the image to reload the snapshot. This one's a little uglier to read as it contains % encoded characters
Code:
javascript:(function()%7Bvar vidDiv %3D document.getElementById("video")%3B function loadSnapshot()%7B%09vidDiv.style.background %3D "url('cgi-bin%2Fsnapshot.cgi%3F" %2B new Date().getTime() %2B "') 50%25 50%25 %2F contain no-repeat rgb(0%2C 0%2C 0)"%3B%7D loadSnapshot()%3B vidDiv.addEventListener("click"%2CloadSnapshot)%7D)()
Dahua should really implement something like this when plugins fail to load. These bookmarklets are pretty simple but might need some modification for your specific use case. You could also convert this to a userscript to make it run automatically.
How do I use the bookmarlet after I've created it?
Simply load the camera's page then click the bookmarklet. The snapshot one adds a cache busting timestamp to the url and reloads the snapshot when you click the image.
Code:
/Snapshot version without % encoding (won't work without encoding) for easier reading
var vidDiv = document.getElementById("video");
function loadSnapshot(){
vidDiv.style.background = "url('cgi-bin/snapshot.cgi?" + new Date().getTime() + "') 50% 50 / contain no-repeat rgb(0, 0, 0)";
}
loadSnapshot();
vidDiv.addEventListener("click",loadSnapshot);
/ % encoded version of the mjpeg one in case your browser can't handle the non-encoded version
javascript:(function()%7Bjavascript%3A(document.getElementById(%22video%22).style.background%20%3D%20%22url('cgi-bin%2Fmjpg%2Fvideo.cgi%3Fchannel%3D1%26subtype%3D2')%2050%25%2050%25%20%2F%20contain%20no-repeat%20rgb(0%2C%200%2C%200)%22)()%7D)()
Last edited: