commit 3454a59e99f9106018876a4039f97301a302ea60 Author: jcli Date: Tue Oct 20 16:26:28 2015 -0700 dial spec 1.7 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..cb029e8 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +*.o +client/dialclient +server/dialserver +server/tests/run_tests diff --git a/Changelog b/Changelog new file mode 100644 index 0000000..0906af8 --- /dev/null +++ b/Changelog @@ -0,0 +1,55 @@ +--------------------------------------------------------------------- +Version 1.0.5 (06edbce) +--------------------------------------------------------------------- +Server changes: + - Update to DIAL specificiation 1.7.2 + - CORE compliance security patch + - Added CORS compliance test scripts + +--------------------------------------------------------------------- +Version 1.0.4 (1673785) +--------------------------------------------------------------------- +Server changes: + - Update to DIAL specificiation 1.7 + - Catch SIGTERM so that we don't self terminate. + +--------------------------------------------------------------------- +Version 1.0.2 (1673785) +--------------------------------------------------------------------- +Server changes: + - Fix an application state bug when the application is launched + without using DIAL. + - Remove unnecessary functionality from Mongoose. + - Use constant values for DIAL port. + - Propery reap child processes. + +Client (test tool) changes: + - None + +--------------------------------------------------------------------- +Version 1.0.1 (1601607) +--------------------------------------------------------------------- +General Changes: + - Simplified directory structure. + - Version.txt changed to Version.h. + - moved main Makefile into src dir. + +Server changes: + - Server configuration options moved into dial_options.h. + - Added logic to walk/proc to see if the named app (eg Netflix) + is running before attempting to start/kill the app. + - Improved payload handling: + - Explicitly define payload size. + - Added logic to check validity of payload, and send HTTP 400 + "bad request" responses to requests with improper payloads. + - Added URL encoding for payloads. + - Added logic to compare launch payload on subsequent launch + requests. + +Client (test tool) changes: + - small change to printed format of server names. + +--------------------------------------------------------------------- +Version 1.0 (1416215) +--------------------------------------------------------------------- +Initial release. diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..0ab73c0 --- /dev/null +++ b/LICENSE @@ -0,0 +1,19 @@ +Copyright (c) 2015 Netflix, Inc. +All rights reserved. +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: +· Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. +· Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. +THIS SOFTWARE IS PROVIDED BY NETFLIX, INC. AND CONTRIBUTORS "AS IS" AND ANY +EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL NETFLIX OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, +INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY +OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, +EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/README b/README new file mode 100644 index 0000000..befd198 --- /dev/null +++ b/README @@ -0,0 +1,78 @@ +-------------------------------------------------------------------------------- +Building the DIAL server +-------------------------------------------------------------------------------- +1) Define the TARGET environment variable to point to the CC compiler prefix + for your target platform. + + +2) Run make, passing in your TARGET value. + + For example: + TARGET=/usr/local/i686-DIAL-EXAMPLE/bin/i686-DIAL-EXAMPLE make + +-------------------------------------------------------------------------------- +Running the DIAL server +-------------------------------------------------------------------------------- +The DIAL server should be started as a service, after the platform's networking +has been initialized, and it should remain running at all times (a daemon +process in the system). + + +-------------------------------------------------------------------------------- +Building the DIAL client +-------------------------------------------------------------------------------- +The DIAL client is a standalone C++ console application you can use to test +a running DIAL server implementation on your device. Unlike the server, which +is built for, and meant to run on your device, the client is meant to run on +your desktop (development) machine. + +The DIAL client uses CURL to send HTTP REST commands to the DIAL server, so to +build the client, you need to ensure that the CURL dependencies are +defined properly. + +Alternatively, you can build against a different, current version of libcurl. +Adjust the INCLUDES and LDFLAGS definitions to point to your actual libcurl +header and library locations. In most cases, you can omit the TARGET define. + +Note: the -rpath argument passed to LDFLAGS specifies the libcurl location +to the runtime linker. + +-------------------------------------------------------------------------------- +Running the DIAL client in interactive (menu) mode +-------------------------------------------------------------------------------- +1) The DIAL client application must be running in the same subnet as the + DIAL server. + +2) Start the client: ./dialclient (or ./dialclient -m) + The on-screen menu will list all available actions. + +-------------------------------------------------------------------------------- +Running the DIAL client in conformance test (non-interactive) mode +-------------------------------------------------------------------------------- +1) The DIAL client application must be running in the same subnet as the + DIAL server. + +2) Start the client: + ./dialclient -i [input-file] [-o output-file] [-a server-IP-addr] + + In script-driven mode, the client reads in an input-file, executes the + instructions in the input-file, and generates a + report. The default file locations (which can be overridden) are: + ./dialclient_input.txt + ./report.html + +-------------------------------------------------------------------------------- +DIAL client Usage +-------------------------------------------------------------------------------- +When running the DIAL client, you have the following options +usage: dialclient