Skip to content

Commit

Permalink
http://www.lavrsen.dk/foswiki/bin/view/Motion/MotionStreamAuthPatch
Browse files Browse the repository at this point in the history
  • Loading branch information
AngelCarpintero authored and AngelCarpintero committed Nov 23, 2009
1 parent eda2a1c commit 55d4ae9
Show file tree
Hide file tree
Showing 10 changed files with 1,127 additions and 18 deletions.
4 changes: 3 additions & 1 deletion CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ Features
* Atom optimizacion in configure.in (Peter Holik)
http://www.lavrsen.dk/foswiki/bin/view/Motion/AtomOptimizations
* Allow to change Standard method ( PAL / NECAM / SECAM ) (Angel Carpintero)

* Add authentication methods 'Basic Authentication' and 'Digest Authentication'
to the "Live Stream Server". (Michael Finsterbusch)
http://www.lavrsen.dk/foswiki/bin/view/Motion/MotionStreamAuthPatch

Bugfixes
* Fix fd leaks in external pipe. (Angel Carpintero)
Expand Down
9 changes: 8 additions & 1 deletion CREDITS
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,8 @@ Angel Carpintero
* Added support for V4L2_PIX_FMT_SBGGR8 ( bayer ), V4L2_PIX_FMT_SN9C10X, V4L2_PIX_FMT_MJPEG and V4L2_PIX_FMT_UYVY.
* Added a FreeBSD directory to allow people from BSD to get a daily version and create a port.
* Removed mysql dependency from debian package and added a note to setup motion to run as daemon to create the pid file.
* Changed the way configure search mysql headers and libs, added 3 parameters to configure --without-mysql to disable support, --with- mysql-include directory of mysql.h and --with-mysql-lib directory of libmysqlclient.a or libmysqlclient.so
* Changed the way configure search mysql headers and libs, added 3 parameters to configure --without-mysql to disable support,
--with-mysql-include directory of mysql.h and --with-mysql-lib directory of libmysqlclient.a or libmysqlclient.so
* Fix an error in FreeBSD , the use of capture even fields depends on height value.
http://www.lavrsen.dk/twiki/bin/view/Motion/BugReport2006x12x03x073610
* Fixed autodetection for VIA cpu , no needed to use --without-optimizecpu. Added many others.
Expand Down Expand Up @@ -448,6 +449,12 @@ Stephen Farrugia
* Fixing the division by zero problem.
This makes motion a lot more stable.

Michael Finsterbusch

* Add authentication methods 'Basic Authentication' and 'Digest Authentication'
to the "Live Stream Server".
http://www.lavrsen.dk/foswiki/bin/view/Motion/MotionStreamAuthPatch

Miguel Freitas
* Came up with the round robing idea.

Expand Down
2 changes: 1 addition & 1 deletion Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ VIDEO_OBJ = @VIDEO@
OBJ = motion.o logger.o conf.o draw.o jpegutils.o vloopback_motion.o $(VIDEO_OBJ) \
netcam.o netcam_ftp.o netcam_jpeg.o netcam_wget.o track.o \
alg.o event.o picture.o rotate.o webhttpd.o \
stream.o @FFMPEG_OBJ@
stream.o md5.o @FFMPEG_OBJ@
SRC = $(OBJ:.o=.c)
DOC = CHANGELOG COPYING CREDITS INSTALL README motion_guide.html
EXAMPLES = *.conf motion.init-Debian motion.init-RH motion.init-FreeBSD.sh
Expand Down
24 changes: 23 additions & 1 deletion conf.c
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@ struct config conf_template = {
stream_maxrate: 1,
stream_localhost: 1,
stream_limit: 0,
stream_auth_method: 0,
stream_authentication: NULL,
webcontrol_port: 0,
webcontrol_localhost: 1,
webcontrol_html_output: 1,
Expand Down Expand Up @@ -1004,6 +1006,26 @@ config_param config_params[] = {
print_int
},
{
"stream_auth_method",
"# Set the authentication method (default: 0)\n"
"# 0 = disabled \n"
"# 1 = Basic authentication\n"
"# 2 = MD5 digest (the safer authentication)\n",
0,
CONF_OFFSET(stream_auth_method),
copy_int,
print_int
},
{
"stream_authentication",
"# Authentication for the http based control. Syntax username:password\n"
"# Default: not defined (Disabled)",
1,
CONF_OFFSET(stream_authentication),
copy_string,
print_string
},
{
"webcontrol_port",
"\n############################################################\n"
"# HTTP Based Control\n"
Expand Down Expand Up @@ -2179,7 +2201,7 @@ static void usage()
printf("-c config\t\tFull path and filename of config file.\n");
printf("-d level\t\tDebug mode.\n");
printf("-p process_id_file\tFull path and filename of process id file (pid file).\n");
printf("-l log file \tFull path and filename of log file.\n");
printf("-l log file \t\tFull path and filename of log file.\n");
printf("-h\t\t\tShow this screen.\n");
printf("\n");
printf("Motion is configured using a config file only. If none is supplied,\n");
Expand Down
2 changes: 2 additions & 0 deletions conf.h
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,8 @@ struct config {
int stream_maxrate;
int stream_localhost;
int stream_limit;
int stream_auth_method;
const char *stream_authentication;
int webcontrol_port;
int webcontrol_localhost;
int webcontrol_html_output;
Expand Down
18 changes: 9 additions & 9 deletions configure
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.64 for motion trunk-r471.
# Generated by GNU Autoconf 2.64 for motion trunk-r472.
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
Expand Down Expand Up @@ -546,8 +546,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='motion'
PACKAGE_TARNAME='motion'
PACKAGE_VERSION='trunk-r471'
PACKAGE_STRING='motion trunk-r471'
PACKAGE_VERSION='trunk-r472'
PACKAGE_STRING='motion trunk-r472'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''

Expand Down Expand Up @@ -1210,7 +1210,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures motion trunk-r471 to adapt to many kinds of systems.
\`configure' configures motion trunk-r472 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
Expand Down Expand Up @@ -1271,7 +1271,7 @@ fi

if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of motion trunk-r471:";;
short | recursive ) echo "Configuration of motion trunk-r472:";;
esac
cat <<\_ACEOF
Expand Down Expand Up @@ -1412,7 +1412,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
motion configure trunk-r471
motion configure trunk-r472
generated by GNU Autoconf 2.64
Copyright (C) 2009 Free Software Foundation, Inc.
Expand Down Expand Up @@ -2009,7 +2009,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by motion $as_me trunk-r471, which was
It was created by motion $as_me trunk-r472, which was
generated by GNU Autoconf 2.64. Invocation command line was
$ $0 $@
Expand Down Expand Up @@ -5790,7 +5790,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by motion $as_me trunk-r471, which was
This file was extended by motion $as_me trunk-r472, which was
generated by GNU Autoconf 2.64. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
Expand Down Expand Up @@ -5850,7 +5850,7 @@ Report bugs to the package provider."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
motion config.status trunk-r471
motion config.status trunk-r472
configured by $0, generated by GNU Autoconf 2.64,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
Expand Down
Loading

0 comments on commit 55d4ae9

Please sign in to comment.