-
Notifications
You must be signed in to change notification settings - Fork 137
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Release 2.9.1 DB tracking, Email logger and remote connect code chang…
…es (#156) * support dynamic variables when directory path for error and sent are Added to new outbound message * Allow using parameters in the path for sentDir and errorDir * Socket Command Processor enhancements Allow different formats to be returned in the response to a socket command processor Change command to exit as being exit the local instance running command processor remote. Add "shutdown" as command to terminate OpenAS2 server from remote command procesor. * Enhanced documentation for release * Remove mistaken pasted text * Make sure it returns an error message when userId/Password are incorrect. * Helper script to use remote socket command interface * Remove unused import * Support filtering based on additional conditions * Pass throwable instead of making 2 log calls allowing decision to log stacktrace to be made down the chain * Pass throwable * Support additional filters on logging * Fix STATE field value lookup * Use app generated timestamps Add additional SQL stmt logging at TRACE level for debugging * Documentation updates for logging * Updated with remote script information. * Final release notes for 2.9.1 * Updated POM's for 2.9.1 * Improving documentation for the remote command processor * Update documentation around remote command processor
- Loading branch information
1 parent
ca5271c
commit bb250db
Showing
22 changed files
with
631 additions
and
522 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
#!/bin/bash | ||
set -e | ||
# purpose: runs the remote OpenAS2 connect application | ||
x=`basename $0` | ||
|
||
function usage() { | ||
echo "Connect to a running instance of OpenAS2." | ||
echo "usage: ${x} <-u user ID> <-P password> [-h host] [-p port] [-c cipher]" | ||
echo " WHERE" | ||
echo " user ID = the user ID configured for the socket command processor module" | ||
echo " password = the password configured for the socket command processor module" | ||
echo " Can be set as OPENAS2_SOCKET_PWD environment variable" | ||
echo " host = hostname or IP address of OpenAS2 server. Defaults to \"localhost\" if not provided." | ||
echo " port = port that the OpenAS2 socket command processor is running on. Defaults to 14321 if not provided." | ||
echo " cipher = anonymous cipher for the OpenAS2 socket command processor connection. Defaults to whatever is in the compiled jar if not provided." | ||
echo "" | ||
echo " eg. $0 -u MyuserId -p MySecret" | ||
echo " $0 -u MyuserId -p MySecret -h as2.mydomain.com" | ||
echo " $0 -u MyuserId -p MySecret -h as2.mydomain.com -c SSL_DH_anon_WITH_RC4_128_MD5" | ||
exit 1 | ||
} | ||
|
||
if test $# -lt 2; then | ||
usage | ||
fi | ||
|
||
HOST_NAME=localhost | ||
HOST_PORT=14321 | ||
|
||
while getopts "u:p:h:P:" opt; do | ||
case ${opt} in | ||
u ) OPENAS2_SOCKET_UID=$OPTARG | ||
;; | ||
P ) OPENAS2_SOCKET_PWD=$OPTARG | ||
;; | ||
h ) HOST_NAME=$OPTARG | ||
;; | ||
p ) HOST_PORT=$OPTARG | ||
;; | ||
c ) CIPHER=$OPTARG | ||
;; | ||
\? ) usage | ||
;; | ||
esac | ||
done | ||
|
||
if [ ! -z $CIPHER ]; then | ||
SET_CIPHER="-DCmdProcessorSocketCipher=$CIPHER" | ||
else | ||
SET_CIPHER="" | ||
fi | ||
binDir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" | ||
|
||
# Backwards compatibility: use value from pid_file if pid_file has a value and openas2_pid has no value. | ||
# | ||
if [ -z $JAVA_HOME ]; then | ||
OS=$(uname -s) | ||
|
||
if [[ "${OS}" == *Darwin* ]]; then | ||
# Mac OS X platform | ||
JAVA_HOME=$(/usr/libexec/java_home) | ||
elif [[ "${OS}" == *Linux* ]]; then | ||
# Linux platform | ||
JAVA_HOME=$(dirname $(dirname $(readlink -f $(which java)))) | ||
elif [[ "${OS}" == *MINGW* ]]; then | ||
# Windows NT platform | ||
echo "Windows not supported by this script" | ||
fi | ||
fi | ||
|
||
if [ -z $JAVA_HOME ]; then | ||
echo "ERROR: Cannot find JAVA_HOME" | ||
exit 1 | ||
fi | ||
|
||
CMD=`echo "${JAVA_HOME}/bin/java ${SET_CIPHER} -cp .:${binDir}/remote/* org.openas2.remote.CommandLine ${HOST_NAME} ${HOST_PORT} ${OPENAS2_SOCKET_UID} ${OPENAS2_SOCKET_PWD}"` | ||
echo | ||
echo Running ${CMD} | ||
echo | ||
${CMD} | ||
RETVAL="$?" | ||
exit $RETVAL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.