BlueIris Indigo Plugin

Posted on
Mon Feb 19, 2018 3:25 am
CliveS offline
Posts: 771
Joined: Jan 10, 2016
Location: Medomsley, County Durham, UK

Re: BlueIris Indigo Plugin

:oops: :oops: :oops: Update - Now working - I did not delete the /Preferences file :oops: :oops: :oops:

I decided to update from 0.4.1 to 0.6.0.
Removed the 0.4 plugin completely and restarted Indigo .

Installed 0.6.0
Code: Select all
19 Feb 2018, 09:13:53
   Reloading plugin "BlueIris Plugin 0.6.5"
   Starting plugin "BlueIris Plugin 0.6.5" (pid 2803)
   BlueIris Plugin                 
   BlueIris Plugin                 ================================================ Initializing New Plugin Session =================================================
   BlueIris Plugin                 Plugin name:                   BlueIris Plugin
   BlueIris Plugin                 Plugin version:                0.6.5
   BlueIris Plugin                 Plugin ID:                     com.GlennNZ.indigoplugin.BlueIris
   BlueIris Plugin                 Indigo version:                7.1.1
   BlueIris Plugin                 Python version:                2.7.10 (default, Feb  7 2017, 00:08:15) [GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)]
   BlueIris Plugin                 Install Path :                 /Library/Application Support/Perceptive Automation/Indigo 7/Plugins/BlueIris.indigoPlugin/Contents/Server Plugin
   BlueIris Plugin                 Path to Gifsicle :             /Library/Application Support/Perceptive Automation/Indigo 7/Plugins/BlueIris.indigoPlugin/Contents/Server Plugin/gifsicle/1.91/bin/giflossy
   BlueIris Plugin                 ==================================================================================================================================
   BlueIris Plugin Error           Error in plugin execution InitializeMain:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "plugin.py", line 104, in __init__
ValueError: invalid literal for int() with base 10: ''

   Stopping plugin "BlueIris Plugin 0.6.5" (pid 2803)
   Stopped plugin "BlueIris Plugin 0.6.5"

CliveS

Indigo 2023.2.0 : macOS Ventura 13.6.3 : Mac Mini M2 : 8‑core CPU and 10‑core GPU : 8 GB : 256GB SSD
----------------------------------------------------------------------------------
The best way to get the right answer on the Internet is not to ask a question, it's to post the wrong answer

Posted on
Mon Feb 19, 2018 4:32 am
GlennNZ offline
User avatar
Posts: 1565
Joined: Dec 07, 2014
Location: Central Coast, Australia

Re: BlueIris Indigo Plugin

CliveS wrote:
:oops: :oops: :oops: Update - Now working - I did not delete the /Preferences file :oops: :oops: :oops:


Thanks.
Damn hard to find those upgrade bugs -but will see if can fix that one.

0.6.6
Is up and should fix that for others.

Glenn

Posted on
Mon Feb 19, 2018 6:07 am
CliveS offline
Posts: 771
Joined: Jan 10, 2016
Location: Medomsley, County Durham, UK

Re: BlueIris Indigo Plugin

Tried a Test from BI,

Code: Select all
 Feb 2018, 11:46:12
   BlueIris Plugin Debug           New Http Handler thread:Thread-7, total threads: 4
   BlueIris Plugin Debug           Received Http POST
   BlueIris Plugin Debug           Sending HTTP 200 Response
   BlueIris Plugin Debug           /Front_Door/TEST/1/True
   BlueIris Plugin Debug           List of Results Equals:['', 'Front_Door', 'TEST', '1', 'True']  and length of listresults:5
   BlueIris Plugin Debug           Trigger Motion for this Camera:Front_Door
   BlueIris Plugin Debug           triggerCheck run.  device.id:1853076733 Camera:Front_Door
   BlueIris Plugin Debug           downloadImage Called
   BlueIris Plugin Debug           Image:  Getting url:http://192.168.1.33:1234/image/Front_Door?w=1920 with path:/Users/indigo/Documents/Indigo-BlueIris/Front_Door.jpg
   BlueIris Plugin Debug           AnimateGif Called: In a New thread:
   BlueIris Plugin Debug           New Thread Camera:Front_Door & Number of Active Threads:5
   BlueIris Plugin Debug           newThreadDownload Some Images Called
   BlueIris Plugin Debug           listfilenames to make into anim:
   BlueIris Plugin Debug           new filename/Users/indigo/Documents/Indigo-BlueIris/Front_Door/Animated.gif
   BlueIris Plugin Debug           "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/BlueIris.indigoPlugin/Contents/Server Plugin/gifsicle/1.91/bin/giflossy" --delay 50 --colors 256 --loopcount --lossy=150  > /Users/indigo/Documents/Indigo-BlueIris/Front_Door/Animated.gif
   BlueIris Plugin Debug           giflossy/sicle return code:1 output:None error:None



I have a tmp folder with 15 x jpg files (0.jpg,1.jpg.....14.jpg) , all 8 bytes long and cannot be opened, also Animated.gif at zero bytes and a Front_Door.jpg at 8 bytes that also can't open.
I obviously have something missing, possibly from the 0.5 beta which I did not install?

CliveS

Indigo 2023.2.0 : macOS Ventura 13.6.3 : Mac Mini M2 : 8‑core CPU and 10‑core GPU : 8 GB : 256GB SSD
----------------------------------------------------------------------------------
The best way to get the right answer on the Internet is not to ask a question, it's to post the wrong answer

Posted on
Mon Feb 19, 2018 2:17 pm
GlennNZ offline
User avatar
Posts: 1565
Joined: Dec 07, 2014
Location: Central Coast, Australia

BlueIris Indigo Plugin

CliveS wrote:
Tried a Test from BI,

I have a tmp folder with 15 x jpg files (0.jpg,1.jpg.....14.jpg) , all 8 bytes long and cannot be opened, also Animated.gif at zero bytes and a Front_Door.jpg at 8 bytes that also can't open.
I obviously have something missing, possibly from the 0.5 beta which I did not install?


Hi Clive,
Thanks for continuing to troubleshoot. Shouldn’t be missing anything.

If the jpgs are 8 bytes long then the images can’t have been downloaded from BI Server. This is not yet a Anim Gif issue - more no images are downloading.

1. Are the other images (one up from tmp) there and okay?
Just re-read and seen Front_door also at 8 bytes.

For some reason we are not able to download or save images from BI server.

Is it setup correctly -
Port is 1234?
IP is 192.168.1.333?

If you type this in a browser what happens? (will need to add BI server username password in the popup)
Code: Select all
http://192.168.1.33:1234/image/Front_Door?w=1920


If you open the 8 byte file in TextEdit - what are the 8 bytes ?

May be a permission folder issue.... however given that it is creating files probably not.
Or most like a BI server user permissions issue?
- try with different user options; don't think are any restrictions of user accessing images - but check that user and/or try a different BI Server user.

& Finally; could check below (but don't think we have got to this code yet):
2. How old is your Mac - we use the Mac tool sips to convert to gifs which has been around for a while. From terminal type ‘sips’ and see whether anything runs?

Glenn

Posted on
Mon Feb 19, 2018 7:22 pm
Professor Falken offline
User avatar
Posts: 289
Joined: Mar 29, 2015

Re: BlueIris Indigo Plugin

Awesome plugin!

I had this up and running on the first attempt. Really cool.

Have already added some schedule based camera actions, and they seem to work great. I think I really like the idea of using Indigo to manage notifications and camera actions. Seems like this will allow a lot of serious customizations based on various house states or other monitored conditions. I think some of this could similarly be handled by profiles in BI, but I look forward to building some very custom logic based on your plugin. I especially like the idea you mentioned of having the plugin's "triggers" being separate from those in BI (if I understood this correctly) such that BI would still log "Alerts" and tag the recoded video as it always does, but Indigo could control whether BI "triggers" actually perform the various Indigo actions. This will be useful (I think) in the scenario I posted a few pages back to prevent my neighbor's 4:30 am headlights on my lawn from triggering a motion-overnight notification every night.

Also looking forward to trying out the gifs.

a few questions:

1) Should I go ahead and paste the variable based code into the alert boxes in BI to create the camera triggers back to I7, or is that system about to change so much with the http server that I should just wait for the current Beta to merge with the released version before adding that functionality?

2) What do you do when you add a new camera to your overall system? I am still building my security camera system. If I add a camera, then add it to BI, do I need to go back to the config and re-trigger the "search for cameras" button. If so, does this leave previously created plugin camera devices and their dependencies intact, or will they all have to be deleted/recreated? When I tried adding a new camera device via the usual Indigo add-device method, it didn't seem like it asked for enough info to really add a new camera from BI.

3) Best practices question: Does it matter, when I give the plugin my BI credentials, whether I use my own admin ones or should I create a new user with Admin privileges to be used by the Indigo plugin?

4) Maybe I'm thinking about this wrong, but might there be a way for the plugin to erase its various saved images/gifs after a period of time? I'm picturing folders filling up with days/weeks/month's worth of triggered images/GIFs that were sent along as a notification. Does the plugin keep all of these, or does it just overwrite in the same location each time? Obviously this data is also being robustly saved back on the blue iris drive if needed more permanently, are these images/GIFs also saving on my Indigo Mac in the plugin created folders?

Posted on
Mon Feb 19, 2018 7:37 pm
GlennNZ offline
User avatar
Posts: 1565
Joined: Dec 07, 2014
Location: Central Coast, Australia

Re: BlueIris Indigo Plugin

Professor Falken wrote:
Awesome plugin!
I had this up and running on the first attempt. Really cool.
Also looking forward to trying out the gifs.
I especially like the idea you mentioned of having the plugin's "triggers" being separate from those in BI (if I understood this correctly) such that BI would still log "Alerts" and tag the recoded video as it always does, but Indigo could control whether BI "triggers" actually perform the various Indigo actions. This will be useful (I think) in the scenario I posted a few pages back to prevent my neighbor's 4:30 am headlights on my lawn from triggering a motion-overnight notification every night.


Thanks for the feedback.
Probably would move to the http server version currently at version 0.6.6 - in Server Branch and help test that.
https://github.com/Ghawken/IndigoPlugin ... /tag/0.6.6

It is working well (for me!) and more robust, quicker and likely less future issues. (plus gets ride of log entries)

re: 4:30am scenario:
Yes exactly.
The Camera Device Custom State - PluginTriggeringEnabled.
This defaults to enabled - so any camera based trigger will run. It also becomes enabled when plugin starts or restarts.
But if set to Disabled via an Action (specific Action to turn on/off) then no trigger for this camera will run until it is re:enabled, or Indigo, or the Plugin restarts.
With BlueIris everything will continue, recording, motion etc. Its just turning of Indigo triggering - so could use overnight; or when home to stop Gif's being sent etc. (& BI will still record)

a few questions:
1) Should I go ahead and paste the variable based code into the alert boxes in BI to create the camera triggers back to I7, or is that system about to change so much with the http server that I should just wait for the current Beta to merge with the released version before adding that functionality?


To get the most out of the plugin (at least triggering) there does need to be feedback to Indigo from Blue Iris.

I would update to http server version (to help testing) and use the web alert suggested in that documentation. This enables On and Off sensing (and will soon aid trigger for motion off)

Also adds another Device Camera State: lastMotionTriggerType - which tells us the type of BI camera event occur, from motion, to test, to audio etc.

2) What do you do when you add a new camera to your overall system? I am still building my security camera system. If I add a camera, then add it to BI, do I need to go back to the config and re-trigger the "search for cameras" button. If so, does this leave previously created plugin camera devices and their dependencies intact, or will they all have to be deleted/recreated? When I tried adding a new camera device via the usual Indigo add-device method, it didn't seem like it asked for enough info to really add a new camera from BI.


Just click the generate Cameras Button. Won't delete any devices, and will aid any new cameras found.
Admin Users - also can access different Cameras I have found (e.g. disabled ones)

Do Not add a Camera Device yourself - might work if you get everything right - but more likely will cause some major issues.
Likewise do not add Main Server Device yourself - use the button

3) Best practices question: Does it matter, when I give the plugin my BI credentials, whether I use my own admin ones or should I create a new user with Admin privileges to be used by the Indigo plugin?

Not sure matters - but different user would be my advice - so at least when look in BI look can see logins/etc.

4) Maybe I'm thinking about this wrong, but might there be a way for the plugin to erase its various saved images/gifs after a period of time? I'm picturing folders filling up with days/weeks/month's worth of triggered images/GIFs that were sent along as a notification. Does the plugin keep all of these, or does it just overwrite in the same location each time? Obviously this data is also being robustly saved back on the blue iris drive if needed more permanently, are these images/GIFs also saving on my Indigo Mac in the plugin created folders?


Decided not to erase old images currently - certainly easier to see what is working/not working.
But does reuse everything - so no risk of major increase in storage. Once created once, will not get any bigger in size.
They are stored locally at
Code: Select all
 /Users/Username/Documents/Indigo-BlueIris/  & /CameraName/Animated.gif

Hence can use them to be sent as Imsg or notification.

Welcome to keep the questions coming!

Glenn

Posted on
Mon Feb 19, 2018 8:51 pm
Professor Falken offline
User avatar
Posts: 289
Joined: Mar 29, 2015

Re: BlueIris Indigo Plugin

Updated to the 0.6.6 Beta.

Copied the start/stop trigger http into the appropriate fields in the BI camera config.

But when I test, I get error12007 (error requesting page).

I have the correct Indigo IP and port. Port is configured in the plugin to match.
Last edited by Professor Falken on Mon Feb 19, 2018 8:59 pm, edited 1 time in total.

Posted on
Mon Feb 19, 2018 8:58 pm
GlennNZ offline
User avatar
Posts: 1565
Joined: Dec 07, 2014
Location: Central Coast, Australia

Re: BlueIris Indigo Plugin

Professor Falken wrote:
Updated to the 0.6.6 Beta.
Coppied the start/stop trigger http into the appropriate fields in the BI camera config.
But when I test, I get error12007 (error requesting page).


Double check the Plugin Config settings particularly checking the Port used. (default is 4556)

Check when starting the Plugin it says HTTP Server started on Port 4556 (or whatever port you are using)

12007 - Google tells me that 'server name' can't be found. What have you entered?


Code: Select all
When Triggered
http://IndigoIPAddress:PluginPortSelected/&CAM/&TYPE/&PROFILE/True
POST text: Indigo

Request again when trigger is reset
http://IndigoIPAddress:PluginPortSelected/&CAM/&TYPE/&PROFILE/False
POST text: Indigo


Also double check you haven't typed the http:// - bit in BlueIris - it selects it via a pull down box!
(I'll put money on that being the issue)

https://github.com/Ghawken/IndigoPlugin ... /README.md

Posted on
Mon Feb 19, 2018 9:07 pm
GlennNZ offline
User avatar
Posts: 1565
Joined: Dec 07, 2014
Location: Central Coast, Australia

Re: BlueIris Indigo Plugin

See above in bold.
Glenn

Posted on
Mon Feb 19, 2018 9:09 pm
Professor Falken offline
User avatar
Posts: 289
Joined: Mar 29, 2015

Re: BlueIris Indigo Plugin

12007 - Google tells me that 'server name' can't be found. What have you entered?


IP of the indigo machine:4556

I have used this default port in the config

Tried reloading the plugin. It does show the http server listening:

Code: Select all
   Started plugin "BlueIris Plugin 0.6.6"
   BlueIris Plugin                 Http Server Listening on TCP port 4556

Posted on
Mon Feb 19, 2018 9:10 pm
GlennNZ offline
User avatar
Posts: 1565
Joined: Dec 07, 2014
Location: Central Coast, Australia

Re: BlueIris Indigo Plugin

GlennNZ wrote:
Professor Falken wrote:
Code: Select all
When Triggered
http://IndigoIPAddress:PluginPortSelected/&CAM/&TYPE/&PROFILE/True
POST text: Indigo

Request again when trigger is reset
http://IndigoIPAddress:PluginPortSelected/&CAM/&TYPE/&PROFILE/False
POST text: Indigo


Also double check you haven't typed the http:// - bit in BlueIris - it selects it via a pull down box!
(I'll put money on that being the issue)


Posted on
Mon Feb 19, 2018 9:10 pm
Professor Falken offline
User avatar
Posts: 289
Joined: Mar 29, 2015

Re: BlueIris Indigo Plugin

Also double check you haven't typed the http:// - bit in BlueIris - it selects it via a pull down box!
(I'll put money on that being the issue)


Ha, yes. That was it.

Posted on
Mon Feb 19, 2018 9:12 pm
CliveS offline
Posts: 771
Joined: Jan 10, 2016
Location: Medomsley, County Durham, UK

Re: BlueIris Indigo Plugin

Glenn

GlennNZ wrote:

If the jpgs are 8 bytes long then the images can’t have been downloaded from BI Server. This is not yet a Anim Gif issue - more no images are downloading.

1. Are the other images (one up from tmp) there and okay?
Just re-read and seen Front_door also at 8 bytes.


Not a good day yesterday, just rechecked and all the .jpg files are actually 8KB size (not 8 bytes as I originally stated :? )

GlennNZ wrote:
If you open the 8 byte file in TextEdit - what are the 8 bytes ?


Inside the Front_Door.jpg (and the 0-14.jpg files) is HTML!!!

Code: Select all
<!-- saved from url=(0022)http://internet.e-mail -->
 
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<style type="text/css">
body { font-family: Helvetica,Arial,sans-serif;font-size: small; background-color:#2d82aa;
}

.button {
     padding: 5px 10px;
     display: inline;
     background: #c6e4ec repeat-x bottom;
     border: none;
     color: #052730;
     cursor: pointer;
     font-weight: bold;
     border-radius: 5px;
     -moz-border-radius: 5px;
     -webkit-border-radius: 5px;
     text-shadow: 1px 1px #ebf4f6;
     }
 .button:hover {
     background-position: 0 -48px;
     }
 .button:active {
     background-position: 0 top;
     position: relative;
     top: 1px;
     padding: 6px 10px 4px;
     }
 
 }
</style>
<title>Blue Iris Login</title>


<script type="text/javascript">

   function getUrlVars() {
       var vars = {};
       var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {vars[key] = value;} );
       return vars;
   }

   function hex_md5(a){return rstr2hex(rstr_md5(str2rstr_utf8(a)))}
   function hex_hmac_md5(a,b){return rstr2hex(rstr_hmac_md5(str2rstr_utf8(a),str2rstr_utf8(b)))}
   function md5_vm_test(){return hex_md5("abc").toLowerCase()=="900150983cd24fb0d6963f7d28e17f72"}
   function rstr_md5(a){return binl2rstr(binl_md5(rstr2binl(a),a.length*8))}
   function rstr_hmac_md5(c,f){var e=rstr2binl(c);if(e.length>16){e=binl_md5(e,c.length*8)}var a=Array(16),d=Array(16);for(var b=0;b<16;b++){a[b]=e[b]^909522486;d[b]=e[b]^1549556828}var g=binl_md5(a.concat(rstr2binl(f)),512+f.length*8);return binl2rstr(binl_md5(d.concat(g),512+128))}
   function rstr2hex(c){var f="0123456789abcdef";var b="";var a;for(var d=0;d<c.length;d++){a=c.charCodeAt(d);b+=f.charAt((a>>>4)&15)+f.charAt(a&15)}return b}
   function str2rstr_utf8(c){var b="";var d=-1;var a,e;while(++d<c.length){a=c.charCodeAt(d);e=d+1<c.length?c.charCodeAt(d+1):0;if(55296<=a&&a<=56319&&56320<=e&&e<=57343){a=65536+((a&1023)<<10)+(e&1023);d++}if(a<=127){b+=String.fromCharCode(a)}else{if(a<=2047){b+=String.fromCharCode(192|((a>>>6)&31),128|(a&63))}else{if(a<=65535){b+=String.fromCharCode(224|((a>>>12)&15),128|((a>>>6)&63),128|(a&63))}else{if(a<=2097151){b+=String.fromCharCode(240|((a>>>18)&7),128|((a>>>12)&63),128|((a>>>6)&63),128|(a&63))}}}}}return b}
   function rstr2binl(b){var a=Array(b.length>>2);for(var c=0;c<a.length;c++){a[c]=0}for(var c=0;c<b.length*8;c+=8){a[c>>5]|=(b.charCodeAt(c/8)&255)<<(c%32)}return a}
   function binl2rstr(b){var a="";for(var c=0;c<b.length*32;c+=8){a+=String.fromCharCode((b[c>>5]>>>(c%32))&255)}return a}
   function binl_md5(p,k){p[k>>5]|=128<<((k)%32);p[(((k+64)>>>9)<<4)+14]=k;var o=1732584193;var n=-271733879;var m=-1732584194;var l=271733878;for(var g=0;g<p.length;g+=16){var j=o;var h=n;var f=m;var e=l;o=md5_ff(o,n,m,l,p[g+0],7,-680876936);l=md5_ff(l,o,n,m,p[g+1],12,-389564586);m=md5_ff(m,l,o,n,p[g+2],17,606105819);n=md5_ff(n,m,l,o,p[g+3],22,-1044525330);o=md5_ff(o,n,m,l,p[g+4],7,-176418897);l=md5_ff(l,o,n,m,p[g+5],12,1200080426);m=md5_ff(m,l,o,n,p[g+6],17,-1473231341);n=md5_ff(n,m,l,o,p[g+7],22,-45705983);o=md5_ff(o,n,m,l,p[g+8],7,1770035416);l=md5_ff(l,o,n,m,p[g+9],12,-1958414417);m=md5_ff(m,l,o,n,p[g+10],17,-42063);n=md5_ff(n,m,l,o,p[g+11],22,-1990404162);o=md5_ff(o,n,m,l,p[g+12],7,1804603682);l=md5_ff(l,o,n,m,p[g+13],12,-40341101);m=md5_ff(m,l,o,n,p[g+14],17,-1502002290);n=md5_ff(n,m,l,o,p[g+15],22,1236535329);o=md5_gg(o,n,m,l,p[g+1],5,-165796510);l=md5_gg(l,o,n,m,p[g+6],9,-1069501632);m=md5_gg(m,l,o,n,p[g+11],14,643717713);n=md5_gg(n,m,l,o,p[g+0],20,-373897302);o=md5_gg(o,n,m,l,p[g+5],5,-701558691);l=md5_gg(l,o,n,m,p[g+10],9,38016083);m=md5_gg(m,l,o,n,p[g+15],14,-660478335);n=md5_gg(n,m,l,o,p[g+4],20,-405537848);o=md5_gg(o,n,m,l,p[g+9],5,568446438);l=md5_gg(l,o,n,m,p[g+14],9,-1019803690);m=md5_gg(m,l,o,n,p[g+3],14,-187363961);n=md5_gg(n,m,l,o,p[g+8],20,1163531501);o=md5_gg(o,n,m,l,p[g+13],5,-1444681467);l=md5_gg(l,o,n,m,p[g+2],9,-51403784);m=md5_gg(m,l,o,n,p[g+7],14,1735328473);n=md5_gg(n,m,l,o,p[g+12],20,-1926607734);o=md5_hh(o,n,m,l,p[g+5],4,-378558);l=md5_hh(l,o,n,m,p[g+8],11,-2022574463);m=md5_hh(m,l,o,n,p[g+11],16,1839030562);n=md5_hh(n,m,l,o,p[g+14],23,-35309556);o=md5_hh(o,n,m,l,p[g+1],4,-1530992060);l=md5_hh(l,o,n,m,p[g+4],11,1272893353);m=md5_hh(m,l,o,n,p[g+7],16,-155497632);n=md5_hh(n,m,l,o,p[g+10],23,-1094730640);o=md5_hh(o,n,m,l,p[g+13],4,681279174);l=md5_hh(l,o,n,m,p[g+0],11,-358537222);m=md5_hh(m,l,o,n,p[g+3],16,-722521979);n=md5_hh(n,m,l,o,p[g+6],23,76029189);o=md5_hh(o,n,m,l,p[g+9],4,-640364487);l=md5_hh(l,o,n,m,p[g+12],11,-421815835);m=md5_hh(m,l,o,n,p[g+15],16,530742520);n=md5_hh(n,m,l,o,p[g+2],23,-995338651);o=md5_ii(o,n,m,l,p[g+0],6,-198630844);l=md5_ii(l,o,n,m,p[g+7],10,1126891415);m=md5_ii(m,l,o,n,p[g+14],15,-1416354905);n=md5_ii(n,m,l,o,p[g+5],21,-57434055);o=md5_ii(o,n,m,l,p[g+12],6,1700485571);l=md5_ii(l,o,n,m,p[g+3],10,-1894986606);m=md5_ii(m,l,o,n,p[g+10],15,-1051523);n=md5_ii(n,m,l,o,p[g+1],21,-2054922799);o=md5_ii(o,n,m,l,p[g+8],6,1873313359);l=md5_ii(l,o,n,m,p[g+15],10,-30611744);m=md5_ii(m,l,o,n,p[g+6],15,-1560198380);n=md5_ii(n,m,l,o,p[g+13],21,1309151649);o=md5_ii(o,n,m,l,p[g+4],6,-145523070);l=md5_ii(l,o,n,m,p[g+11],10,-1120210379);m=md5_ii(m,l,o,n,p[g+2],15,718787259);n=md5_ii(n,m,l,o,p[g+9],21,-343485551);o=safe_add(o,j);n=safe_add(n,h);m=safe_add(m,f);l=safe_add(l,e)}return Array(o,n,m,l)}
   function md5_cmn(h,e,d,c,g,f){return safe_add(bit_rol(safe_add(safe_add(e,h),safe_add(c,f)),g),d)}
   function md5_ff(g,f,k,j,e,i,h){return md5_cmn((f&k)|((~f)&j),g,f,e,i,h)}
   function md5_gg(g,f,k,j,e,i,h){return md5_cmn((f&j)|(k&(~j)),g,f,e,i,h)}
   function md5_hh(g,f,k,j,e,i,h){return md5_cmn(f^k^j,g,f,e,i,h)}
   function md5_ii(g,f,k,j,e,i,h){return md5_cmn(k^(f|(~j)),g,f,e,i,h)}
   function safe_add(a,d){var c=(a&65535)+(d&65535);var b=(a>>16)+(d>>16)+(c>>16);return(b<<16)|(c&65535)}
   function bit_rol(a,b){return(a<<b)|(a>>>(32-b))};

   function getSession()
    {
      var i,x,y,ARRcookies=document.cookie.split(";");
      for (i=0; i<ARRcookies.length; i++ )
      {
         x=ARRcookies[i].substr(0,ARRcookies[i].indexOf("="));
         y=ARRcookies[i].substr(ARRcookies[i].indexOf("=")+1);
         x=x.replace(/^\s+|\s+$/g,"");

         if (x=="session")
         {
            return unescape(y);
         }
      }
    }
   
    function login()
    {
       var a = document.getElementById('user').value+":"+getSession()+":"+ document.getElementById('password').value;
       window.location = "/?page=" + getUrlVars()["page"] + "&login=" + hex_md5( a );
    }

    window.onload = function()
   {
      document.getElementById('user').focus();
    }


function submitenter(myfield,e)
{
var keycode;
if (window.event) keycode = window.event.keyCode;
else if (e) keycode = e.which;
else return true;

if (keycode == 13)
   {
   myfield.form.submit();
   return false;
   }
else
   return true;
}



</script>

</head>

<body style="background-color: #425963">

<form method="POST" action="javascript:login()" autocomplete="on" >
   <table border="0" width="100%">
      <tr>
         <td align="center"><b><font color="#FFFFFF" size="4">Highsteads</font></b></td>
      </tr>
      <tr>
         <td align="center">&nbsp;</td>
      </tr>
      <tr>
         <td align="center"><font color="#FFFFFF">User:</font></td>
      </tr>
      <tr>
         <td align="center"><input type="text" name="user" id="user" size="20"></td>
      </tr>
      <tr>
         <td align="center"><font color="#FFFFFF">Password:
   </font>
   </td>
      </tr>
      <tr>
         <td align="center"><input type="password" name="password" id="password" size="20" onKeyPress="return submitenter(this,event)"></td>
      </tr>
      <tr>
         <td align="center">
   &nbsp;</td>
      </tr>
      <tr>
         <td align="center">
   <input id='login-button' type='submit' value='Login'</td>
      </tr>
   </table>
   <p>&nbsp;</p>
</form>

</body>

</html>

GlennNZ wrote:
If you type this in a browser what happens? (will need to add BI server username password in the popup
http://192.168.1.33:1234/image/Front_Door?w=1920

I get a picture from the camera

GlennNZ wrote:
& Finally; could check below (but don't think we have got to this code yet):
2. How old is your Mac - we use the Mac tool sips to convert to gifs which has been around for a while. From terminal type ‘sips’ and see whether anything runs?

The Mac is a 2011 i7 Mac Mini Server running Sierra 10.12.6
Mac-mini:~ indigo$ sips
sips 10.4.4 - scriptable image processing system.

Code: Select all
 Starting plugin "BlueIris Plugin 0.6.6" (pid 18414)
   BlueIris Plugin                 
   BlueIris Plugin                 ================================================ Initializing New Plugin Session =================================================
   BlueIris Plugin                 Plugin name:                   BlueIris Plugin
   BlueIris Plugin                 Plugin version:                0.6.6
   BlueIris Plugin                 Plugin ID:                     com.GlennNZ.indigoplugin.BlueIris
   BlueIris Plugin                 Indigo version:                7.1.1
   BlueIris Plugin                 Python version:                2.7.10 (default, Feb  7 2017, 00:08:15) [GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)]
   BlueIris Plugin                 Install Path :                 /Library/Application Support/Perceptive Automation/Indigo 7/Plugins/BlueIris.indigoPlugin/Contents/Server Plugin
   BlueIris Plugin                 Path to Gifsicle :             /Library/Application Support/Perceptive Automation/Indigo 7/Plugins/BlueIris.indigoPlugin/Contents/Server Plugin/gifsicle/1.91/bin/giflossy
   BlueIris Plugin                 ==================================================================================================================================
   Started plugin "BlueIris Plugin 0.6.6"
   BlueIris Plugin                 Http Server Listening on TCP port 4556

CliveS

Indigo 2023.2.0 : macOS Ventura 13.6.3 : Mac Mini M2 : 8‑core CPU and 10‑core GPU : 8 GB : 256GB SSD
----------------------------------------------------------------------------------
The best way to get the right answer on the Internet is not to ask a question, it's to post the wrong answer

Posted on
Mon Feb 19, 2018 9:20 pm
GlennNZ offline
User avatar
Posts: 1565
Joined: Dec 07, 2014
Location: Central Coast, Australia

Re: BlueIris Indigo Plugin

CliveS wrote:
Glenn

GlennNZ wrote:
If the jpgs are 8 bytes long then the images can’t have been downloaded from BI Server. This is not yet a Anim Gif issue - more no images are downloading.
Not a good day yesterday, just rechecked and all the .jpg files are actually 8KB size (not 8 bytes as I originally stated :? )


Thanks for all the info.
That does seem quite odd - has to be BlueIris authentication issue. Do you want to try changing the authentication settings for that user and particular the web-server authentication settings for authentication: non-Lan only etc. options.

This is that Html Page:
Image

Does this mean anything? Have you got a custom BI login page - or are there some settings I haven't found?

Either-way Odd.

Let me know your BI Web Server settings.
Probably will be http/https or similar issue and can have a look at Download Image code changes...

G

Posted on
Mon Feb 19, 2018 10:03 pm
GlennNZ offline
User avatar
Posts: 1565
Joined: Dec 07, 2014
Location: Central Coast, Australia

Re: BlueIris Indigo Plugin

CliveS wrote:
Glenn


Clive

It'll be this setting here, in BI Server

Image

These are my settings (although the plugin does authenticate regardless traffic)
I do have Authentication form non-LAN only, tested works fine with authentication all connections as well.
(as said the plugin does authenicate)

I think the relevant part is the
'use secure session keys and login page'
Must display this login page for all access - hence cannot download images.

Meanwhile the plugin does for the most part use the session keys (just not available as option for the images)

Odd that the URL that we checked didn't take you to it though?

Give it a try.

Glenn
Last edited by GlennNZ on Mon Feb 19, 2018 10:26 pm, edited 1 time in total.

Page 6 of 11 1 ... 3, 4, 5, 6, 7, 8, 9 ... 11

Who is online

Users browsing this forum: No registered users and 2 guests