Send Motion-user mailing list submissions to
        motion-user@lists.sourceforge.net

To subscribe or unsubscribe via the World Wide Web, visit
        https://lists.sourceforge.net/lists/listinfo/motion-user
or, via email, send a message with subject or body 'help' to
        motion-user-requ...@lists.sourceforge.net

You can reach the person managing the list at
        motion-user-ow...@lists.sourceforge.net

When replying, please edit your Subject line so it is more specific
than "Re: Contents of Motion-user digest..."


Today's Topics:

   1. Re: mpjpeg fails on wansview 1080p (Mike Wilson)
   2. Re: mpjpeg fails on wansview 1080p (John Baker)
   3. Re: mpjpeg fails on wansview 1080p (John Baker)
   4. Re: mpjpeg fails on wansview 1080p (tosiara)
   5. Re: Motion stops detection during recording of    previous
      detection (tosiara)


----------------------------------------------------------------------

Message: 1
Date: Sun, 07 Aug 2016 04:07:15 +0000
From: Mike Wilson <knobby2...@gmail.com>
Subject: Re: [Motion-user] mpjpeg fails on wansview 1080p
To: Motion discussion list <motion-user@lists.sourceforge.net>
Message-ID:
        <CAAVeUCof9RuWffqih_eTQc+rZ_zWpQfdDssr7QKk1uN=TtqL=a...@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"

A 401 HTTP code is unauthorized. Are you sure your camera is able to handle
auth in this manner?

On Sat, Aug 6, 2016 at 2:57 PM John Baker <jba...@dryfish.org.uk> wrote:

> No, I appear to have copied/pasted/deleted a char. Debug level 9:
>
> [1] [INF] [NET] [Aug 06 19:43:40] netcam_http_build_url: Netcam has
> flags: HTTP/1.0: 1 HTTP/1.1: 0 Keep-Alive OFF.
> [1] [INF] [NET] [Aug 06 19:43:40] netcam_http_build_url: Camera connect
> string is ''GET /mjpeg/stream.cgi?chn=0 HTTP/1.0
> Host: 192.168.0.102
> User-Agent: Motion-netcam/Unofficial-Git-UNKNOWN
> Connection: close
> Authorization: Basic xxxxx
>
> '' End of camera connect string.
> [1] [INF] [NET] [Aug 06 19:43:40] netcam_http_request: about to try to
> connect, time #0
> [1] [INF] [NET] [Aug 06 19:43:40] netcam_connect: disconnecting netcam
> since keep-alive not set.
> [1] [INF] [NET] [Aug 06 19:43:40] netcam_connect: with no keepalive, new
> socket created fd 7
> [1] [INF] [NET] [Aug 06 19:43:40] netcam_connect: re-using socket 7
> since keepalive is set.
> [1] [INF] [NET] [Aug 06 19:43:40] netcam_read_first_header: Received
> first header ('HTTP/1.0 401 Unauthorized')
> [1] [INF] [NET] [Aug 06 19:43:40] netcam_read_first_header: HTTP Result
> code 401
>
> I've checked the real base64 string (xxxx) being sent as the
> Authorisation header and it's correct, so the issue is the camera
> returns 401 in this instance causing libjpeg to fail. But, motion should
> be checking the HTTP status code returned and not assuming 200, ie it's
> 401 (for whatever reason) and this isn't reported to the log.
>
> So there's an easy logging improvement for anyone hacking the C and I'll
> figure out why the camera doesn't authenticate the client.
>
>
> On Sat, Aug 6, 2016, at 07:38 PM, Mike Wilson wrote:
> > Are you turkey using the URL htp:// instead of http?
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Motion-user mailing list
> Motion-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/motion-user
> http://www.lavrsen.dk/twiki/bin/view/Motion/WebHome
>
-------------- next part --------------
An HTML attachment was scrubbed...

------------------------------

Message: 2
Date: Sun, 07 Aug 2016 07:14:22 +0100
From: John Baker <jba...@dryfish.org.uk>
Subject: Re: [Motion-user] mpjpeg fails on wansview 1080p
To: motion-user@lists.sourceforge.net
Message-ID:
        <1470550462.1103663.688165769.64979...@webmail.messagingengine.com>
Content-Type: text/plain

Not sure. I'm going to have a play with it - but - there is a problem in
motion where by it's not checking the HTTP status code for 200 before
proceeding with fetching images, so it's reporting the wrong error in
the standard log (It should say, authentication failed).

On Sun, Aug 7, 2016, at 05:07 AM, Mike Wilson wrote:
> A 401 HTTP code is unauthorized. Are you sure your camera is able to
> handle
> auth in this manner?
> 
> On Sat, Aug 6, 2016 at 2:57 PM John Baker <jba...@dryfish.org.uk> wrote:
> 
> > No, I appear to have copied/pasted/deleted a char. Debug level 9:
> >
> > [1] [INF] [NET] [Aug 06 19:43:40] netcam_http_build_url: Netcam has
> > flags: HTTP/1.0: 1 HTTP/1.1: 0 Keep-Alive OFF.
> > [1] [INF] [NET] [Aug 06 19:43:40] netcam_http_build_url: Camera connect
> > string is ''GET /mjpeg/stream.cgi?chn=0 HTTP/1.0
> > Host: 192.168.0.102
> > User-Agent: Motion-netcam/Unofficial-Git-UNKNOWN
> > Connection: close
> > Authorization: Basic xxxxx
> >
> > '' End of camera connect string.
> > [1] [INF] [NET] [Aug 06 19:43:40] netcam_http_request: about to try to
> > connect, time #0
> > [1] [INF] [NET] [Aug 06 19:43:40] netcam_connect: disconnecting netcam
> > since keep-alive not set.
> > [1] [INF] [NET] [Aug 06 19:43:40] netcam_connect: with no keepalive, new
> > socket created fd 7
> > [1] [INF] [NET] [Aug 06 19:43:40] netcam_connect: re-using socket 7
> > since keepalive is set.
> > [1] [INF] [NET] [Aug 06 19:43:40] netcam_read_first_header: Received
> > first header ('HTTP/1.0 401 Unauthorized')
> > [1] [INF] [NET] [Aug 06 19:43:40] netcam_read_first_header: HTTP Result
> > code 401
> >
> > I've checked the real base64 string (xxxx) being sent as the
> > Authorisation header and it's correct, so the issue is the camera
> > returns 401 in this instance causing libjpeg to fail. But, motion should
> > be checking the HTTP status code returned and not assuming 200, ie it's
> > 401 (for whatever reason) and this isn't reported to the log.
> >
> > So there's an easy logging improvement for anyone hacking the C and I'll
> > figure out why the camera doesn't authenticate the client.
> >
> >
> > On Sat, Aug 6, 2016, at 07:38 PM, Mike Wilson wrote:
> > > Are you turkey using the URL htp:// instead of http?
> >
> >
> > ------------------------------------------------------------------------------
> > _______________________________________________
> > Motion-user mailing list
> > Motion-user@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/motion-user
> > http://www.lavrsen.dk/twiki/bin/view/Motion/WebHome
> >
> ------------------------------------------------------------------------------
> _______________________________________________
> Motion-user mailing list
> Motion-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/motion-user
> http://www.lavrsen.dk/twiki/bin/view/Motion/WebHome



------------------------------

Message: 3
Date: Sun, 07 Aug 2016 07:25:02 +0100
From: John Baker <jba...@dryfish.org.uk>
Subject: Re: [Motion-user] mpjpeg fails on wansview 1080p
To: motion-user@lists.sourceforge.net
Message-ID:
        <1470551102.1104984.688166449.34a55...@webmail.messagingengine.com>
Content-Type: text/plain

So being more awake this morning, I now spot the problem. The camera
wishes to use HTTP digest authentication, which I guess motion doesn't
support (another on the todo list Mr Dave / Joseph ?:). 

http://stackoverflow.com/questions/2384230/what-is-digest-authentication

Example:

> HEAD /mjpeg/stream.cgi?chn=0 HTTP/1.1
> Host: 192.168.0.102
> User-Agent: curl/7.49.1
> Accept: */*
>
< HTTP/1.1 401 Unauthorized
< WWW-Authenticate: Digest realm="IPCamera Login",
nonce="f35b3a998c0b964d21d99da3f8880f14", qop="auth"

> HEAD /mjpeg/stream.cgi?chn=0 HTTP/1.1
> Host: 192.168.0.102
> Authorization: Digest username="visitor", realm="IPCamera Login", 
> nonce="f35b3a998c0b964d21d99da3f8880f14", uri="/mjpeg/stream.cgi?chn=0", 
> cnonce="MWY1N2M3NmUzMjNlODIxM2ZjMzAxYTcyNTIzMjA0MTY=", nc=00000001, qop=auth, 
> response="3bb6cbc93342432432421104ebeed5c3a"
> User-Agent: curl/7.49.1
> Accept: */*
>
< HTTP/1.1 200 OK




------------------------------

Message: 4
Date: Sun, 7 Aug 2016 10:08:51 +0300
From: tosiara <tosi...@gmail.com>
Subject: Re: [Motion-user] mpjpeg fails on wansview 1080p
To: Motion discussion list <motion-user@lists.sourceforge.net>
Message-ID:
        <cachtdwr_sr+or0abgb7y1epw2yersqmx7j5xjze9+iyoagh...@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"

So here we have two issues:
1. motion should better handle 401 or any non-200 http status and show user
friendly error
2. digest auth support

The first would probably be an easy code change
But the second would be a challenge. We can implement digest auth. Or.
There was a discussion already to replace all the manual http code by some
web library that provides better support and better maintained. But that
requires also quite a lot of efforts to change the code

On Sun, Aug 7, 2016 at 9:25 AM, John Baker <jba...@dryfish.org.uk> wrote:

> So being more awake this morning, I now spot the problem. The camera
> wishes to use HTTP digest authentication, which I guess motion doesn't
> support (another on the todo list Mr Dave / Joseph ?:).
>
> http://stackoverflow.com/questions/2384230/what-is-digest-authentication
>
> Example:
>
> > HEAD /mjpeg/stream.cgi?chn=0 HTTP/1.1
> > Host: 192.168.0.102
> > User-Agent: curl/7.49.1
> > Accept: */*
> >
> < HTTP/1.1 401 Unauthorized
> < WWW-Authenticate: Digest realm="IPCamera Login",
> nonce="f35b3a998c0b964d21d99da3f8880f14", qop="auth"
>
> > HEAD /mjpeg/stream.cgi?chn=0 HTTP/1.1
> > Host: 192.168.0.102
> > Authorization: Digest username="visitor", realm="IPCamera Login", nonce="
> f35b3a998c0b964d21d99da3f8880f14", uri="/mjpeg/stream.cgi?chn=0", cnonce="
> MWY1N2M3NmUzMjNlODIxM2ZjMzAxYTcyNTIzMjA0MTY=", nc=00000001, qop=auth,
> response="3bb6cbc93342432432421104ebeed5c3a"
> > User-Agent: curl/7.49.1
> > Accept: */*
> >
> < HTTP/1.1 200 OK
>
>
> ------------------------------------------------------------
> ------------------
> _______________________________________________
> Motion-user mailing list
> Motion-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/motion-user
> http://www.lavrsen.dk/twiki/bin/view/Motion/WebHome
>
-------------- next part --------------
An HTML attachment was scrubbed...

------------------------------

Message: 5
Date: Sun, 7 Aug 2016 10:11:56 +0300
From: tosiara <tosi...@gmail.com>
Subject: Re: [Motion-user] Motion stops detection during recording of
        previous detection
To: Mark <pic1...@yahoo.com>
Cc: Motion discussion list <motion-user@lists.sourceforge.net>
Message-ID:
        <CACHTdwQ7HL7eYWSSmAqA0dNo+c=x-pkn3zgntwcycvpv+lq...@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"

You should be fine with rpi. I run motion on multiple arm devices and
compiled that from sources

On Fri, Aug 5, 2016 at 5:55 PM, Mark <pic1...@yahoo.com> wrote:

> That's what it's supposed to do. It doesn't for some reason.
> If I set it to 30 for example, as I recall, it recorded 40 seconds. I was
> moving around for 3 minutes but didn't record more that one movie.
> It doesn't sound like it's normal. Maybe I should re-install Motion from
> source and see what the latest and greatest of MrDave's has to offer.
> Is it a pain on a RPI-3? Anyone know?
>
>
>
>
> ------------------------------
> *From:* tosiara <tosi...@gmail.com>
> *To:* Mark <pic1...@yahoo.com>; Motion discussion list <motion-user@lists.
> sourceforge.net>
> *Cc:* Joerg Weber <mot...@alcatraz.ath.cx>
> *Sent:* Friday, August 5, 2016 10:29 AM
> *Subject:* Re: [Motion-user] Motion stops detection during recording of
> previous detection
>
> If you set "event_gap 60" - do you always get videos of 60 seconds length?
> event_gap option means if there is no movement for 60 sec - event is
> finished and video file flushed and closed. If there was movement at 50
> second and then silence - the counter will again count 60 seconds before
> finishing event.
> In other words, this option means "how long to wait if there is no more
> motion detected, before event is ended"
>
> On Fri, Aug 5, 2016 at 4:30 PM, Mark <pic1...@yahoo.com> wrote:
>
> Sorry, yes I meant event_gap.
> The motion is triggered properly and the recording starts. but after the
> event_gap, it stops recording although the subject is still moving.
> Thanks
> Mai
>
>
> ------------------------------
> *From:* Joerg Weber <mot...@alcatraz.ath.cx>
> *To:* Mark <pic1...@yahoo.com>; Motion discussion list <motion-user@lists.
> sourceforge.net>
> *Sent:* Friday, August 5, 2016 9:21 AM
> *Subject:* Re: [Motion-user] Motion stops detection during recording of
> previous detection
>
> Hello Mark,
>
> do you mean 'event_gap' instead of 'stop_gap' maybe? Could you please
> describe this problem a bit more in detail? I'm not sure I fully understand
> yet.
>
>
> Brgds Joerg.
>
>
>
> 5. August 2016 15:16 Uhr, "Mark" <pic1...@yahoo.com> schrieb:
>
> Hello World;
> I am setting up motion for RPI3 and noticed I can't get the movie to
> continue recording after the stop_gap of any number (tried the 60 default,
> 90, 5, 10 etc)
> It doesn't seem to understand to continue recording while there is
> movement.
> What do I have to change to get this to record for the duration of
> movement? Everything else works like a charm.
> Sorry but suffering from noob syndrome :)
> Mai
>
>
>
>
> ------------------------------ ------------------------------
> ------------------
>
> ______________________________ _________________
> Motion-user mailing list
> Motion-user@lists.sourceforge. net
> https://lists.sourceforge.net/ lists/listinfo/motion-user
> http://www.lavrsen.dk/twiki/ bin/view/Motion/WebHome
>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...

------------------------------

------------------------------------------------------------------------------


------------------------------

_______________________________________________
Motion-user mailing list
Motion-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/motion-user


End of Motion-user Digest, Vol 123, Issue 15
********************************************

Reply via email to