upgrade to 2.5.1
This commit is contained in:
parent
e48b9b75ad
commit
b7439faced
@ -1,2 +1,3 @@
|
|||||||
tog-pegasus-2.4.1.Beta-1.tar.gz
|
tog-pegasus-2.4.1.Beta-1.tar.gz
|
||||||
pegasus-2.5.tar.gz
|
pegasus-2.5.tar.gz
|
||||||
|
pegasus-2.5.1.tar.gz
|
||||||
|
134
pegasus-2.5.1-PIE.patch
Normal file
134
pegasus-2.5.1-PIE.patch
Normal file
@ -0,0 +1,134 @@
|
|||||||
|
--- pegasus/src/Pegasus/Compiler/cmdline/cimmof/Makefile.PIE 2006-01-30 11:17:34.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Compiler/cmdline/cimmof/Makefile 2006-04-06 16:17:54.000000000 -0400
|
||||||
|
@@ -32,6 +32,8 @@
|
||||||
|
DIR = Pegasus/Compiler/cmdline/cimmof
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
LOCAL_DEFINES = -DPEGASUS_CMDLINE_INTERNAL -DPEGASUS_INTERNALONLY
|
||||||
|
|
||||||
|
LIBRARIES = \
|
||||||
|
--- pegasus/src/Pegasus/Compiler/cmdline/cimmofl/Makefile.PIE 2006-01-30 11:17:34.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Compiler/cmdline/cimmofl/Makefile 2006-04-06 16:17:43.000000000 -0400
|
||||||
|
@@ -32,6 +32,8 @@
|
||||||
|
DIR = Pegasus/Compiler/cmdline/cimmofl
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
LOCAL_DEFINES = -DPEGASUS_INTERNALONLY
|
||||||
|
|
||||||
|
PROGRAM = cimmofl
|
||||||
|
--- pegasus/src/Pegasus/ProviderManager2/ProviderAgent/Makefile.PIE 2006-01-30 11:18:16.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/ProviderManager2/ProviderAgent/Makefile 2006-04-05 21:05:58.000000000 -0400
|
||||||
|
@@ -29,11 +29,12 @@
|
||||||
|
#//
|
||||||
|
#//==============================================================================
|
||||||
|
ROOT = ../../../..
|
||||||
|
-
|
||||||
|
DIR = Pegasus/ProviderManager2/ProviderAgent
|
||||||
|
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
LIBRARIES = \
|
||||||
|
pegprovidermanager \
|
||||||
|
pegprovider \
|
||||||
|
@@ -56,4 +57,3 @@
|
||||||
|
tests:
|
||||||
|
|
||||||
|
poststarttests:
|
||||||
|
-
|
||||||
|
--- pegasus/src/Server/Makefile.PIE 2006-01-30 11:19:33.000000000 -0500
|
||||||
|
+++ pegasus/src/Server/Makefile 2006-04-05 21:05:58.000000000 -0400
|
||||||
|
@@ -30,8 +30,11 @@
|
||||||
|
#//==============================================================================
|
||||||
|
ROOT = ../..
|
||||||
|
DIR = Server
|
||||||
|
+
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
LIBRARIES = \
|
||||||
|
pegclient \
|
||||||
|
pegserver \
|
||||||
|
--- pegasus/src/Clients/cimprovider/Makefile.PIE 2006-01-30 11:16:33.000000000 -0500
|
||||||
|
+++ pegasus/src/Clients/cimprovider/Makefile 2006-04-06 16:17:31.000000000 -0400
|
||||||
|
@@ -36,6 +36,8 @@
|
||||||
|
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
LIBRARIES = \
|
||||||
|
pegcliutils \
|
||||||
|
pegclient \
|
||||||
|
--- pegasus/src/Clients/osinfo/Makefile.PIE 2006-01-30 11:16:35.000000000 -0500
|
||||||
|
+++ pegasus/src/Clients/osinfo/Makefile 2006-04-06 16:17:14.000000000 -0400
|
||||||
|
@@ -35,6 +35,8 @@
|
||||||
|
DIR = Clients/osinfo
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
LIBRARIES = \
|
||||||
|
pegcliutils \
|
||||||
|
peggetoopt \
|
||||||
|
--- pegasus/src/Clients/cimuser/Makefile.PIE 2006-01-30 11:16:33.000000000 -0500
|
||||||
|
+++ pegasus/src/Clients/cimuser/Makefile 2006-04-06 16:17:01.000000000 -0400
|
||||||
|
@@ -36,6 +36,8 @@
|
||||||
|
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
LIBRARIES = \
|
||||||
|
pegcliutils \
|
||||||
|
pegclient \
|
||||||
|
--- pegasus/src/Clients/repupgrade/Makefile.PIE 2006-01-30 11:16:36.000000000 -0500
|
||||||
|
+++ pegasus/src/Clients/repupgrade/Makefile 2006-04-06 16:16:37.000000000 -0400
|
||||||
|
@@ -36,6 +36,8 @@
|
||||||
|
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
LOCAL_DEFINES = -DPEGASUS_INTERNALONLY
|
||||||
|
|
||||||
|
LIBRARIES = \
|
||||||
|
--- pegasus/src/Clients/cimauth/Makefile.PIE 2006-01-30 11:16:32.000000000 -0500
|
||||||
|
+++ pegasus/src/Clients/cimauth/Makefile 2006-04-06 16:16:17.000000000 -0400
|
||||||
|
@@ -36,6 +36,8 @@
|
||||||
|
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
LIBRARIES = \
|
||||||
|
pegcliutils \
|
||||||
|
pegclient \
|
||||||
|
--- pegasus/src/Clients/cimconfig/Makefile.PIE 2006-01-30 11:16:32.000000000 -0500
|
||||||
|
+++ pegasus/src/Clients/cimconfig/Makefile 2006-04-06 16:15:59.000000000 -0400
|
||||||
|
@@ -36,6 +36,8 @@
|
||||||
|
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
LIBRARIES = \
|
||||||
|
pegcliutils \
|
||||||
|
pegclient \
|
||||||
|
--- pegasus/src/Clients/wbemexec/Makefile.PIE 2006-01-30 11:16:37.000000000 -0500
|
||||||
|
+++ pegasus/src/Clients/wbemexec/Makefile 2006-04-06 16:15:23.000000000 -0400
|
||||||
|
@@ -36,6 +36,8 @@
|
||||||
|
|
||||||
|
include $(ROOT)/mak/config.mak
|
||||||
|
|
||||||
|
+FLAGS := $(FLAGS:-fPIC=-fPIE)
|
||||||
|
+
|
||||||
|
ifdef PEGASUS_HAS_SSL
|
||||||
|
FLAGS += -DPEGASUS_HAS_SSL -DPEGASUS_SSL_RANDOMFILE
|
||||||
|
SYS_INCLUDES += -I$(OPENSSL_HOME)/include
|
24
pegasus-2.5.1-cmpi-provider-lib.patch
Normal file
24
pegasus-2.5.1-cmpi-provider-lib.patch
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
--- pegasus/src/Pegasus/Config/FixedPropertyTableLinux.h.cmpi_provider_lib 2006-03-14 16:06:37.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Config/FixedPropertyTableLinux.h 2006-04-05 20:06:55.000000000 -0400
|
||||||
|
@@ -65,8 +65,8 @@
|
||||||
|
{"crlStore", PEGASUS_SSL_SERVER_CRL},
|
||||||
|
#endif
|
||||||
|
{"repositoryDir", PEGASUS_REPOSITORY_DIR},
|
||||||
|
- {"providerDir", PEGASUS_PROVIDER_LIB_DIR":/usr/lib/cmpi"},
|
||||||
|
-#else
|
||||||
|
+ {"providerDir", PEGASUS_PROVIDER_LIB_DIR ":" PEGASUS_DEST_LIB_DIR "/cmpi"},
|
||||||
|
+#else /* PEGASUS_OVERRIDE_DEFAULT_RELEASE_DIRS */
|
||||||
|
{"traceFilePath", "/var/opt/tog-pegasus/cache/trace/cimserver.trc"},
|
||||||
|
#if !defined(PEGASUS_USE_SYSLOGS)
|
||||||
|
{"logdir", "/var/opt/tog-pegasus/log"},
|
||||||
|
@@ -84,8 +84,8 @@
|
||||||
|
{"providerDir", "/opt/tog-pegasus/providers/lib"},
|
||||||
|
#endif
|
||||||
|
{"messageDir", "/opt/tog-pegasus/share/locale/ICU_Messages"},
|
||||||
|
-#endif
|
||||||
|
-#endif
|
||||||
|
+#endif /* PEGASUS_OVERRIDE_DEFAULT_RELEASE_DIRS */
|
||||||
|
+#endif /* defined(PEGASUS_USE_RELEASE_DIRS) && !defined(PEGASUS_OS_LSB) */
|
||||||
|
#if defined(PEGASUS_USE_RELEASE_DIRS) && defined(PEGASUS_OS_LSB)
|
||||||
|
{"traceFilePath", "/var/opt/lsb-pegasus/cache/cimserver.trc"},
|
||||||
|
#if !defined(PEGASUS_USE_SYSLOGS)
|
40
pegasus-2.5.1-enable_cql.patch
Normal file
40
pegasus-2.5.1-enable_cql.patch
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
--- pegasus/env_var_Linux.status.enable-cql 2006-03-15 20:33:51.000000000 -0500
|
||||||
|
+++ pegasus/env_var_Linux.status 2006-04-06 15:19:35.000000000 -0400
|
||||||
|
@@ -18,7 +18,7 @@
|
||||||
|
PEGASUS_STAGING_DIR = $(PEGASUS_HOME)/stagingDir
|
||||||
|
endif
|
||||||
|
|
||||||
|
-PEGASUS_DISABLE_CQL=true
|
||||||
|
+PEGASUS_ENABLE_CQL=true
|
||||||
|
PEGASUS_DISABLE_OBJECT_NORMALIZATION=true
|
||||||
|
PEGASUS_DISABLE_PERFINST=yes
|
||||||
|
PEGASUS_ENABLE_CMPI_PROVIDER_MANAGER=true
|
||||||
|
@@ -26,7 +26,6 @@
|
||||||
|
PEGASUS_HAS_SSL=yes
|
||||||
|
PEGASUS_NOASSERTS=yes
|
||||||
|
PEGASUS_PAM_AUTHENTICATION=true
|
||||||
|
-PEGASUS_USE_PAM_STANDALONE_PROC=true
|
||||||
|
PEGASUS_USE_RELEASE_CONFIG_OPTIONS=true
|
||||||
|
PEGASUS_USE_RELEASE_DIRS=true
|
||||||
|
PEGASUS_USE_SYSLOGS=true
|
||||||
|
@@ -64,9 +63,10 @@
|
||||||
|
PEGASUS_LOCAL_AUTH_DIR = $(PEGASUS_VARDATA_CACHE_DIR)/localauth
|
||||||
|
PEGASUS_TRACE_DIR = $(PEGASUS_VARDATA_CACHE_DIR)/trace
|
||||||
|
PEGASUS_TRACE_FILE_PATH = $(PEGASUS_VARDATA_CACHE_DIR)/trace/cimserver.trc
|
||||||
|
+PEGASUS_CONFIG_DIR = /etc/Pegasus
|
||||||
|
PEGASUS_PLANNED_CONFIG_FILE = cimserver_planned.conf
|
||||||
|
PEGASUS_PLANNED_CONFIG_FILE_PATH = \
|
||||||
|
- $(PEGASUS_VARDATA_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)
|
||||||
|
+ $(PEGASUS_CONFIG_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)
|
||||||
|
PEGASUS_CURRENT_CONFIG_FILE = cimserver_current.conf
|
||||||
|
PEGASUS_CURRENT_CONFIG_FILE_PATH = \
|
||||||
|
$(PEGASUS_VARDATA_DIR)/$(PEGASUS_CURRENT_CONFIG_FILE)
|
||||||
|
@@ -74,8 +74,6 @@
|
||||||
|
PEGASUS_LOG_DIR = $(PEGASUS_VARDATA_DIR)/log
|
||||||
|
PEGASUS_INSTALL_LOG = $(PEGASUS_LOG_DIR)/install.log
|
||||||
|
|
||||||
|
-PEGASUS_CONFIG_DIR = /etc/Pegasus
|
||||||
|
-
|
||||||
|
PEGASUS_VARRUN_DIR = /var/run/tog-pegasus
|
||||||
|
PEGASUS_CIMSERVER_START_FILE = $(PEGASUS_VARRUN_DIR)/cimserver.pid
|
||||||
|
CIMSERVER_LOCK_FILE = $(PEGASUS_VARRUN_DIR)/cimserver_start.lock
|
163
pegasus-2.5.1-initscript.patch
Normal file
163
pegasus-2.5.1-initscript.patch
Normal file
@ -0,0 +1,163 @@
|
|||||||
|
--- pegasus/rpm/tog-pegasus.rc.initscript 2006-01-30 11:16:24.000000000 -0500
|
||||||
|
+++ pegasus/rpm/tog-pegasus.rc 2006-04-06 14:38:57.000000000 -0400
|
||||||
|
@@ -1,80 +1,85 @@
|
||||||
|
-#//%2006////////////////////////////////////////////////////////////////////////
|
||||||
|
-#//
|
||||||
|
-#// Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
|
||||||
|
-#// Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
|
||||||
|
-#// Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L.P.;
|
||||||
|
-#// IBM Corp.; EMC Corporation, The Open Group.
|
||||||
|
-#// Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.;
|
||||||
|
-#// IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group.
|
||||||
|
-#// Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
|
||||||
|
-#// EMC Corporation; VERITAS Software Corporation; The Open Group.
|
||||||
|
-#// Copyright (c) 2006 Hewlett-Packard Development Company, L.P.; IBM Corp.;
|
||||||
|
-#// EMC Corporation; Symantec Corporation; The Open Group.
|
||||||
|
-#//
|
||||||
|
-#// Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
-#// of this software and associated documentation files (the "Software"), to
|
||||||
|
-#// deal in the Software without restriction, including without limitation the
|
||||||
|
-#// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
||||||
|
-#// sell copies of the Software, and to permit persons to whom the Software is
|
||||||
|
-#// furnished to do so, subject to the following conditions:
|
||||||
|
-#//
|
||||||
|
-#// THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
|
||||||
|
-#// ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
|
||||||
|
-#// "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
|
||||||
|
-#// LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
|
||||||
|
-#// PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||||
|
-#// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
|
||||||
|
-#// ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||||
|
-#// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
|
-#//
|
||||||
|
-#//==============================================================================
|
||||||
|
-#! /bin/sh
|
||||||
|
-#//
|
||||||
|
-#//%/////////////////////////////////////////////////////////////////////////////
|
||||||
|
-
|
||||||
|
-### BEGIN INIT INFO
|
||||||
|
-# Provides: tog-pegasus
|
||||||
|
-# Required-Start: $syslog $network
|
||||||
|
-# Should-Start: $time
|
||||||
|
-# Required-Stop: $syslog
|
||||||
|
-# Default-Start: 3 5
|
||||||
|
-# Default-Stop: 0 1 2 6
|
||||||
|
-# Description: init script for Pegasus CIM server
|
||||||
|
-### END INIT INFO
|
||||||
|
-
|
||||||
|
-CIMSERVER_BIN=/opt/tog-pegasus/sbin/cimserver
|
||||||
|
+#!/bin/bash
|
||||||
|
+#
|
||||||
|
+# chkconfig: - 98 1
|
||||||
|
+# description: The Open Group Pegasus cimserver initscript
|
||||||
|
+# processname: cimserver
|
||||||
|
+# pidfile: /var/run/tog-pegasus/cimserver.pid
|
||||||
|
+#
|
||||||
|
+CIMSERVER_BIN=/usr/sbin/cimserver
|
||||||
|
prog=cimserver
|
||||||
|
+LOCKFILE=/var/lock/subsys/tog-pegasus
|
||||||
|
+. /etc/rc.d/init.d/functions
|
||||||
|
|
||||||
|
-test -x $CIMSERVER_BIN || exit 5
|
||||||
|
+if [ ! -x $CIMSERVER_BIN ]; then
|
||||||
|
+ echo -n "tog-pegasus $1: $CIMSERVER_BIN not found or not executable.";
|
||||||
|
+ failure;
|
||||||
|
+ exit 1;
|
||||||
|
+fi;
|
||||||
|
+
|
||||||
|
+[ -e /etc/sysconfig/tog-pegasus ] && . /etc/sysconfig/tog-pegasus;
|
||||||
|
+
|
||||||
|
+PEGASUS_SSL_CONF_FILE=${PEGASUS_SSL_CONF_FILE:=/etc/Pegasus/ssl.cnf}
|
||||||
|
+PEGASUS_SSL_CERT_FILE=${PEGASUS_SSL_CERT_FILE:=/etc/Pegasus/server.pem}
|
||||||
|
+PEGASUS_SSL_KEY_FILE=${PEGASUS_SSL_KEY_FILE:=/etc/Pegasus/file.pem}
|
||||||
|
+PEGASUS_SSL_TRUSTSTORE=${PEGASUS_SSL_TRUSTSTORE:=/etc/Pegasus/client.pem}
|
||||||
|
|
||||||
|
-. /lib/lsb/init-functions
|
||||||
|
RETVAL=0
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
- start)
|
||||||
|
+ start)
|
||||||
|
+ if [ ! -e ${PEGASUS_SSL_CONF_FILE} ] || [ ! -e ${PEGASUS_SSL_CERT_FILE} ] ||
|
||||||
|
+ [ ! -e ${PEGASUS_SSL_KEY_FILE} ] || [ ! -e ${PEGASUS_SSL_TRUSTSTORE} ]; then
|
||||||
|
+ if [ -x /usr/share/Pegasus/scripts/genOpenPegasusSSLCerts ]; then
|
||||||
|
+ echo -n "tog-pegasus: Generating cimserver SSL certificates...";
|
||||||
|
+ /usr/share/Pegasus/scripts/genOpenPegasusSSLCerts;
|
||||||
|
+ if [ $? -eq 0 ]; then
|
||||||
|
+ success;
|
||||||
|
+ else
|
||||||
|
+ failure;
|
||||||
|
+ fi;
|
||||||
|
+ echo;
|
||||||
|
+ fi;
|
||||||
|
+ fi;
|
||||||
|
echo -n $"Starting up CIM server: "
|
||||||
|
$CIMSERVER_BIN
|
||||||
|
RETVAL=$?
|
||||||
|
- [ "$RETVAL" -eq 0 ] && log_success_msg $"$prog start" || log_failure_msg $"$prog start"
|
||||||
|
- echo
|
||||||
|
+ if [ "$RETVAL" -eq 0 ]; then
|
||||||
|
+ touch $LOCKFILE;
|
||||||
|
+ success;
|
||||||
|
+ else
|
||||||
|
+ failure;
|
||||||
|
+ fi;
|
||||||
|
+ echo;
|
||||||
|
;;
|
||||||
|
|
||||||
|
stop)
|
||||||
|
echo -n $"Shutting down CIM server: "
|
||||||
|
killproc cimserver
|
||||||
|
RETVAL=$?
|
||||||
|
- [ "$RETVAL" -eq 0 ] && log_success_msg $"$prog stop" || log_failure_msg $"$prog stop"
|
||||||
|
+ if [ "$RETVAL" -eq 0 ]; then
|
||||||
|
+ rm -f $LOCKFILE;
|
||||||
|
+ rm -f /var/run/tog-pegasus/socket/*;
|
||||||
|
+ rm -f /var/run/tog-pegasus/cimserver.pid;
|
||||||
|
+ success;
|
||||||
|
+ else
|
||||||
|
+ failure;
|
||||||
|
+ fi
|
||||||
|
echo
|
||||||
|
;;
|
||||||
|
+
|
||||||
|
status)
|
||||||
|
pid=`pidofproc $CIMSERVER_BIN`
|
||||||
|
RETVAL=$?
|
||||||
|
if [ "$RETVAL" -eq 0 ]; then
|
||||||
|
- echo "CIM server is running"
|
||||||
|
+ echo -n $"CIM server ($pid) is running";
|
||||||
|
+ success;
|
||||||
|
else
|
||||||
|
- echo "CIM server is not running"
|
||||||
|
+ echo -n $"CIM server is not running";
|
||||||
|
+ failure;
|
||||||
|
fi
|
||||||
|
+ echo
|
||||||
|
;;
|
||||||
|
+
|
||||||
|
condrestart)
|
||||||
|
pid=`pidofproc $CIMSERVER_BIN`
|
||||||
|
RETVAL=$?
|
||||||
|
@@ -83,13 +88,18 @@
|
||||||
|
RETVAL=$?;
|
||||||
|
fi;
|
||||||
|
;;
|
||||||
|
+
|
||||||
|
try-restart)
|
||||||
|
- $0 stop && $0 start
|
||||||
|
+ $0 stop && $0 start;
|
||||||
|
+ RETVAL=$?;
|
||||||
|
;;
|
||||||
|
+
|
||||||
|
restart|force-reload)
|
||||||
|
- $0 stop
|
||||||
|
- $0 start
|
||||||
|
+ $0 stop;
|
||||||
|
+ $0 start;
|
||||||
|
+ RETVAL=$?;
|
||||||
|
;;
|
||||||
|
+
|
||||||
|
reload)
|
||||||
|
;;
|
||||||
|
*)
|
26
pegasus-2.5.1-linkflags.patch
Normal file
26
pegasus-2.5.1-linkflags.patch
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
--- pegasus/mak/library.mak.linkflags 2006-01-30 11:16:23.000000000 -0500
|
||||||
|
+++ pegasus/mak/library.mak 2006-04-05 17:11:23.000000000 -0400
|
||||||
|
@@ -40,6 +40,10 @@
|
||||||
|
|
||||||
|
include $(ROOT)/mak/common.mak
|
||||||
|
|
||||||
|
+ifdef PEGASUS_EXTRA_LIBRARY_LINK_FLAGS
|
||||||
|
+ EXTRA_LINK_FLAGS = $(PEGASUS_EXTRA_LIBRARY_LINK_FLAGS)
|
||||||
|
+endif
|
||||||
|
+
|
||||||
|
################################################################################
|
||||||
|
##
|
||||||
|
## Build list of object names.
|
||||||
|
--- pegasus/mak/program.mak.linkflags 2006-01-30 11:16:23.000000000 -0500
|
||||||
|
+++ pegasus/mak/program.mak 2006-04-05 17:10:37.000000000 -0400
|
||||||
|
@@ -38,6 +38,10 @@
|
||||||
|
|
||||||
|
include $(ROOT)/mak/common.mak
|
||||||
|
|
||||||
|
+ifdef PEGASUS_EXTRA_PROGRAM_LINK_FLAGS
|
||||||
|
+ EXTRA_LINK_FLAGS = $(PEGASUS_EXTRA_PROGRAM_LINK_FLAGS)
|
||||||
|
+endif
|
||||||
|
+
|
||||||
|
ifeq ($(OS_TYPE),windows)
|
||||||
|
include $(ROOT)/mak/program-windows.mak
|
||||||
|
endif
|
439
pegasus-2.5.1-local-or-remote-auth.patch
Normal file
439
pegasus-2.5.1-local-or-remote-auth.patch
Normal file
@ -0,0 +1,439 @@
|
|||||||
|
--- pegasus/src/Pegasus/Server/HTTPAuthenticatorDelegator.cpp.local-or-remote-auth 2006-03-10 18:18:37.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Server/HTTPAuthenticatorDelegator.cpp 2006-04-05 20:35:40.000000000 -0400
|
||||||
|
@@ -384,6 +384,9 @@
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
+ // Let Authenticators know whether this user is Local or Remote:
|
||||||
|
+ httpMessage->authInfo->setRemoteUser( httpMessage->fromRemoteHost );
|
||||||
|
+
|
||||||
|
//
|
||||||
|
// Handle authentication:
|
||||||
|
//
|
||||||
|
--- pegasus/src/Pegasus/Security/Authentication/PAMBasicAuthenticatorUnix.cpp.local-or-remote-auth 2006-01-30 11:18:28.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Security/Authentication/PAMBasicAuthenticatorUnix.cpp 2006-04-05 20:40:40.000000000 -0400
|
||||||
|
@@ -48,6 +48,8 @@
|
||||||
|
#include <prot.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+#include <syslog.h>
|
||||||
|
+
|
||||||
|
#if defined (PEGASUS_USE_PAM_STANDALONE_PROC)
|
||||||
|
#include <Pegasus/Common/Logger.h>
|
||||||
|
#include <Pegasus/Common/IPC.h>
|
||||||
|
@@ -131,7 +133,8 @@
|
||||||
|
|
||||||
|
Boolean PAMBasicAuthenticator::authenticate(
|
||||||
|
const String& userName,
|
||||||
|
- const String& password)
|
||||||
|
+ const String& password,
|
||||||
|
+ Boolean isRemoteUser)
|
||||||
|
{
|
||||||
|
PEG_METHOD_ENTER(TRC_AUTHENTICATION,
|
||||||
|
"PAMBasicAuthenticator::authenticate()");
|
||||||
|
@@ -139,7 +142,7 @@
|
||||||
|
Boolean authenticated;
|
||||||
|
|
||||||
|
#if !defined(PEGASUS_USE_PAM_STANDALONE_PROC)
|
||||||
|
- authenticated = _authenticateByPAM(userName, password);
|
||||||
|
+ authenticated = _authenticateByPAM(userName, password, isRemoteUser);
|
||||||
|
#else
|
||||||
|
//
|
||||||
|
// Mutex to Serialize Authentication calls.
|
||||||
|
@@ -147,8 +150,9 @@
|
||||||
|
Tracer::trace(TRC_AUTHENTICATION, Tracer::LEVEL4,
|
||||||
|
"Authentication Mutex lock.");
|
||||||
|
AutoMutex lock(_authSerializeMutex);
|
||||||
|
- authenticated = _pamBasicAuthenticatorStandAlone.authenticate(
|
||||||
|
- userName, password);
|
||||||
|
+ authenticated =
|
||||||
|
+ _pamBasicAuthenticatorStandAlone->authenticate(userName,
|
||||||
|
+ password);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
PEG_METHOD_EXIT();
|
||||||
|
@@ -157,7 +161,8 @@
|
||||||
|
|
||||||
|
Boolean PAMBasicAuthenticator::_authenticateByPAM(
|
||||||
|
const String& userName,
|
||||||
|
- const String& password)
|
||||||
|
+ const String& password,
|
||||||
|
+ Boolean isRemoteUser)
|
||||||
|
{
|
||||||
|
PEG_METHOD_ENTER(TRC_AUTHENTICATION,
|
||||||
|
"PAMBasicAuthenticator::_authenticateByPAM()");
|
||||||
|
@@ -167,6 +172,7 @@
|
||||||
|
pam_handle_t *phandle;
|
||||||
|
char *name;
|
||||||
|
APP_DATA mydata;
|
||||||
|
+ int retcode;
|
||||||
|
|
||||||
|
//
|
||||||
|
// Store the password for PAM authentication
|
||||||
|
@@ -180,13 +186,31 @@
|
||||||
|
// Tracer::trace(TRC_AUTHENTICATION, Tracer::LEVEL4,
|
||||||
|
// "PAMBasicAuthenticator::_authenticateByPAM() - userName = %s; userPassword = %s",
|
||||||
|
// (const char *)userName.getCString(), (const char *)password.getCString());
|
||||||
|
+
|
||||||
|
+ // NOTE: if any pam call should log anything, our syslog socket will be redirected
|
||||||
|
+ // to the AUTH facility, so we need to redirect it back after each pam call.
|
||||||
|
|
||||||
|
//
|
||||||
|
//Call pam_start since you need to before making any other PAM calls
|
||||||
|
//
|
||||||
|
- if ( ( pam_start(service,
|
||||||
|
+
|
||||||
|
+ if ( (retcode = pam_start(service,
|
||||||
|
(const char *)userName.getCString(), &pconv, &phandle) ) != PAM_SUCCESS )
|
||||||
|
{
|
||||||
|
+ closelog();
|
||||||
|
+ openlog("cimserver", LOG_PID, LOG_DAEMON);
|
||||||
|
+ syslog( LOG_ERR, "pam_start failed: %s", pam_strerror(phandle, retcode));
|
||||||
|
+ PEG_METHOD_EXIT();
|
||||||
|
+ return (authenticated);
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+
|
||||||
|
+ if ( (retcode = pam_set_item(phandle, PAM_TTY, isRemoteUser ? "wbemNetwork" : "wbemLocal")) != PAM_SUCCESS )
|
||||||
|
+ {
|
||||||
|
+ pam_end(phandle, 0);
|
||||||
|
+ closelog();
|
||||||
|
+ openlog("cimserver", LOG_PID, LOG_DAEMON);
|
||||||
|
+ syslog( LOG_ERR, "pam_set_item(PAM_TTY=wbem) failed: %s", pam_strerror(phandle, retcode));
|
||||||
|
PEG_METHOD_EXIT();
|
||||||
|
return (authenticated);
|
||||||
|
}
|
||||||
|
@@ -194,7 +218,7 @@
|
||||||
|
//
|
||||||
|
//Call pam_authenticate to authenticate the user
|
||||||
|
//
|
||||||
|
- if ( ( pam_authenticate(phandle, 0) ) == PAM_SUCCESS )
|
||||||
|
+ if ( ( retcode = pam_authenticate(phandle, 0) ) == PAM_SUCCESS )
|
||||||
|
{
|
||||||
|
Tracer::trace(TRC_AUTHENTICATION, Tracer::LEVEL4,
|
||||||
|
"pam_authenticate successful.");
|
||||||
|
@@ -203,22 +227,40 @@
|
||||||
|
//checking for password and account expiration, as well as verifying access
|
||||||
|
//hour restrictions.
|
||||||
|
//
|
||||||
|
- if ( ( pam_acct_mgmt(phandle, 0) ) == PAM_SUCCESS )
|
||||||
|
+
|
||||||
|
+ if ( ( retcode = pam_acct_mgmt(phandle, 0) ) == PAM_SUCCESS )
|
||||||
|
{
|
||||||
|
Tracer::trace(TRC_AUTHENTICATION, Tracer::LEVEL4,
|
||||||
|
"pam_acct_mgmt successful.");
|
||||||
|
authenticated = true;
|
||||||
|
- }
|
||||||
|
+ }else
|
||||||
|
+ {
|
||||||
|
+ closelog();
|
||||||
|
+ openlog("cimserver", LOG_PID, LOG_DAEMON);
|
||||||
|
+ syslog(LOG_ERR, "pam_acct_mgmt failed: %s",pam_strerror(phandle, retcode));
|
||||||
|
+ }
|
||||||
|
+ }else
|
||||||
|
+ {
|
||||||
|
+ closelog();
|
||||||
|
+ openlog("cimserver", LOG_PID, LOG_DAEMON);
|
||||||
|
+ syslog(LOG_ERR, "pam_authenticate failed: %s",pam_strerror(phandle, retcode));
|
||||||
|
}
|
||||||
|
-
|
||||||
|
//
|
||||||
|
//Call pam_end to end our PAM work
|
||||||
|
//
|
||||||
|
pam_end(phandle, 0);
|
||||||
|
+ closelog();
|
||||||
|
+ openlog("cimserver", LOG_PID, LOG_DAEMON);
|
||||||
|
|
||||||
|
- PEG_METHOD_EXIT();
|
||||||
|
+ if ( ! authenticated )
|
||||||
|
+ syslog(LOG_ERR, "PAM authentication failed for %s user: %s",
|
||||||
|
+ isRemoteUser ? "remote" : "local",
|
||||||
|
+ (const char*)userName.getCString()
|
||||||
|
+ );
|
||||||
|
|
||||||
|
+ PEG_METHOD_EXIT();
|
||||||
|
return (authenticated);
|
||||||
|
+
|
||||||
|
}
|
||||||
|
|
||||||
|
Boolean PAMBasicAuthenticator::validateUser(const String& userName)
|
||||||
|
@@ -233,6 +275,7 @@
|
||||||
|
pam_handle_t *phandle;
|
||||||
|
char *name;
|
||||||
|
APP_DATA mydata;
|
||||||
|
+ int retcode;
|
||||||
|
|
||||||
|
const char *service = "wbem";
|
||||||
|
pconv.conv = PAMBasicAuthenticator::pamValidateUserCallback;
|
||||||
|
@@ -241,21 +284,43 @@
|
||||||
|
//
|
||||||
|
// Call pam_start since you need to before making any other PAM calls
|
||||||
|
//
|
||||||
|
- if ( pam_start(service,
|
||||||
|
- (const char *)userName.getCString(), &pconv, &phandle) != PAM_SUCCESS)
|
||||||
|
- {
|
||||||
|
+ if ( (retcode =
|
||||||
|
+ pam_start(service,(const char *)userName.getCString(), &pconv, &phandle)
|
||||||
|
+ ) != PAM_SUCCESS
|
||||||
|
+ )
|
||||||
|
+ {
|
||||||
|
+ closelog();
|
||||||
|
+ openlog("cimserver", LOG_PID, LOG_DAEMON);
|
||||||
|
+ syslog( LOG_ERR, "pam_start() failed: %s", pam_strerror(phandle, retcode));
|
||||||
|
PEG_METHOD_EXIT();
|
||||||
|
return (authenticated);
|
||||||
|
}
|
||||||
|
|
||||||
|
+ if ( (retcode = pam_set_item(phandle, PAM_TTY, "wbemLocal")) != PAM_SUCCESS )
|
||||||
|
+ {
|
||||||
|
+ pam_end(phandle, 0);
|
||||||
|
+ closelog();
|
||||||
|
+ openlog("cimserver", LOG_PID, LOG_DAEMON);
|
||||||
|
+ syslog( LOG_ERR, "pam_set_item(PAM_TTY=wbemLocal) failed: %s", pam_strerror(phandle, retcode));
|
||||||
|
+ PEG_METHOD_EXIT();
|
||||||
|
+ return (authenticated);
|
||||||
|
+ }
|
||||||
|
//
|
||||||
|
// Call pam_acct_mgmt, to check if the user account is valid. This includes
|
||||||
|
// checking for account expiration, as well as verifying access
|
||||||
|
// hour restrictions.
|
||||||
|
//
|
||||||
|
- if ( pam_acct_mgmt(phandle, 0) == PAM_SUCCESS )
|
||||||
|
- {
|
||||||
|
+ if ( (retcode = pam_acct_mgmt(phandle, 0)) == PAM_SUCCESS )
|
||||||
|
+ {
|
||||||
|
authenticated = true;
|
||||||
|
+ }else
|
||||||
|
+ {
|
||||||
|
+ pam_end(phandle, 0);
|
||||||
|
+ closelog();
|
||||||
|
+ openlog("cimserver", LOG_PID, LOG_DAEMON);
|
||||||
|
+ syslog( LOG_ERR, "pam_acct_mgmt() failed: %s", pam_strerror(phandle, retcode));
|
||||||
|
+ PEG_METHOD_EXIT();
|
||||||
|
+ return (authenticated);
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
@@ -263,6 +328,9 @@
|
||||||
|
//
|
||||||
|
pam_end(phandle, 0);
|
||||||
|
|
||||||
|
+ closelog();
|
||||||
|
+ openlog("cimserver", LOG_PID, LOG_DAEMON);
|
||||||
|
+
|
||||||
|
#else
|
||||||
|
//
|
||||||
|
// Mutex to Serialize Authentication calls.
|
||||||
|
--- pegasus/src/Pegasus/Security/Authentication/BasicAuthenticator.h.local-or-remote-auth 2006-01-30 11:18:28.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Security/Authentication/BasicAuthenticator.h 2006-04-05 20:35:40.000000000 -0400
|
||||||
|
@@ -67,7 +67,8 @@
|
||||||
|
*/
|
||||||
|
virtual Boolean authenticate(
|
||||||
|
const String& userName,
|
||||||
|
- const String& password) = 0;
|
||||||
|
+ const String& password,
|
||||||
|
+ Boolean isRemoteUser) = 0;
|
||||||
|
|
||||||
|
/** Construct and return the HTTP Basic authentication challenge header
|
||||||
|
@return A string containing the authentication challenge header.
|
||||||
|
--- pegasus/src/Pegasus/Security/Authentication/BasicAuthenticationHandler.cpp.local-or-remote-auth 2006-01-30 11:18:28.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Security/Authentication/BasicAuthenticationHandler.cpp 2006-04-05 20:35:40.000000000 -0400
|
||||||
|
@@ -138,7 +138,7 @@
|
||||||
|
authInfo->setAuthenticatedUser(userName);
|
||||||
|
authInfo->setAuthenticatedPassword(password);
|
||||||
|
#else
|
||||||
|
- authenticated = _basicAuthenticator->authenticate(userName, password);
|
||||||
|
+ authenticated = _basicAuthenticator->authenticate(userName, password, authInfo->isRemoteUser());
|
||||||
|
|
||||||
|
if (authenticated)
|
||||||
|
{
|
||||||
|
--- pegasus/src/Pegasus/Security/Authentication/PAMBasicAuthenticatorStub.cpp.local-or-remote-auth 2006-01-30 11:18:28.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Security/Authentication/PAMBasicAuthenticatorStub.cpp 2006-04-05 20:35:40.000000000 -0400
|
||||||
|
@@ -92,7 +92,8 @@
|
||||||
|
|
||||||
|
Boolean PAMBasicAuthenticator::authenticate(
|
||||||
|
const String& userName,
|
||||||
|
- const String& password)
|
||||||
|
+ const String& password,
|
||||||
|
+ Boolean isRemoteUser)
|
||||||
|
{
|
||||||
|
PEG_METHOD_ENTER(TRC_AUTHENTICATION,
|
||||||
|
"PAMBasicAuthenticator::authenticate()");
|
||||||
|
--- pegasus/src/Pegasus/Security/Authentication/PAMBasicAuthenticator.h.local-or-remote-auth 2006-01-30 11:18:28.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Security/Authentication/PAMBasicAuthenticator.h 2006-04-05 20:35:40.000000000 -0400
|
||||||
|
@@ -73,7 +73,8 @@
|
||||||
|
*/
|
||||||
|
Boolean authenticate(
|
||||||
|
const String& userName,
|
||||||
|
- const String& password);
|
||||||
|
+ const String& password,
|
||||||
|
+ Boolean isRemoteUser);
|
||||||
|
|
||||||
|
/** Verify PAM account management for the requesting user.
|
||||||
|
@param userName String containing the user name
|
||||||
|
@@ -102,7 +103,8 @@
|
||||||
|
|
||||||
|
Boolean _authenticateByPAM(
|
||||||
|
const String& userName,
|
||||||
|
- const String& password);
|
||||||
|
+ const String& password,
|
||||||
|
+ Boolean isRemoteUser);
|
||||||
|
|
||||||
|
void _createPAMStandalone();
|
||||||
|
|
||||||
|
@@ -158,7 +160,8 @@
|
||||||
|
*/
|
||||||
|
Boolean authenticate(
|
||||||
|
const String& userName,
|
||||||
|
- const String& password);
|
||||||
|
+ const String& password,
|
||||||
|
+ Boolean isRemoteUser);
|
||||||
|
|
||||||
|
/** Verify whether the user is valid.
|
||||||
|
@param userName String containing the user name
|
||||||
|
@@ -220,7 +223,8 @@
|
||||||
|
|
||||||
|
Boolean _authenticateByPAM(
|
||||||
|
const String& userName,
|
||||||
|
- const String& password);
|
||||||
|
+ const String& password,
|
||||||
|
+ Boolean isRemoteUser);
|
||||||
|
|
||||||
|
#if defined(PEGASUS_USE_PAM_STANDALONE_PROC)
|
||||||
|
PAMBasicAuthenticatorStandAlone _pamBasicAuthenticatorStandAlone;
|
||||||
|
--- pegasus/src/Pegasus/Common/AuthenticationInfoRep.cpp.local-or-remote-auth 2006-01-30 11:16:46.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Common/AuthenticationInfoRep.cpp 2006-04-05 20:35:40.000000000 -0400
|
||||||
|
@@ -57,7 +57,8 @@
|
||||||
|
_privileged(false),
|
||||||
|
_authType(String::EMPTY),
|
||||||
|
_authStatus(NEW_REQUEST),
|
||||||
|
- _exportConnection(false)
|
||||||
|
+ _exportConnection(false),
|
||||||
|
+ _remoteUser(true)
|
||||||
|
{
|
||||||
|
PEG_METHOD_ENTER(
|
||||||
|
TRC_AUTHENTICATION, "AuthenticationInfoRep::AuthenticationInfoRep");
|
||||||
|
@@ -180,5 +181,14 @@
|
||||||
|
PEG_METHOD_EXIT();
|
||||||
|
}
|
||||||
|
|
||||||
|
+void AuthenticationInfoRep::setRemoteUser(Boolean remoteUser)
|
||||||
|
+{
|
||||||
|
+ PEG_METHOD_ENTER(TRC_AUTHENTICATION,
|
||||||
|
+ "AuthenticationInfoRep::setRemoteUser");
|
||||||
|
+
|
||||||
|
+ _remoteUser = remoteUser;
|
||||||
|
+
|
||||||
|
+ PEG_METHOD_EXIT();
|
||||||
|
+}
|
||||||
|
|
||||||
|
PEGASUS_NAMESPACE_END
|
||||||
|
--- pegasus/src/Pegasus/Common/HTTPMessage.cpp.local-or-remote-auth 2006-01-30 11:17:04.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Common/HTTPMessage.cpp 2006-04-05 20:35:40.000000000 -0400
|
||||||
|
@@ -119,7 +119,8 @@
|
||||||
|
queueId(queueId_),
|
||||||
|
authInfo(0),
|
||||||
|
acceptLanguagesDecoded(false),
|
||||||
|
- contentLanguagesDecoded(false)
|
||||||
|
+ contentLanguagesDecoded(false),
|
||||||
|
+ fromRemoteHost(true)
|
||||||
|
{
|
||||||
|
if (cimException_)
|
||||||
|
cimException = *cimException_;
|
||||||
|
--- pegasus/src/Pegasus/Common/AuthenticationInfo.h.local-or-remote-auth 2006-01-30 11:16:46.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Common/AuthenticationInfo.h 2006-04-05 20:35:40.000000000 -0400
|
||||||
|
@@ -331,6 +331,22 @@
|
||||||
|
_rep->setClientCertificateChain(clientCertificate);
|
||||||
|
}
|
||||||
|
|
||||||
|
+ /** Indicate whether the user is Remote
|
||||||
|
+ */
|
||||||
|
+ Boolean isRemoteUser() const
|
||||||
|
+ {
|
||||||
|
+ _checkRep();
|
||||||
|
+ return _rep->isRemoteUser();
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ /** Set the Remote User flag
|
||||||
|
+ */
|
||||||
|
+ void setRemoteUser(Boolean remoteUser)
|
||||||
|
+ {
|
||||||
|
+ _checkRep();
|
||||||
|
+ _rep->setRemoteUser(remoteUser);
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
private:
|
||||||
|
|
||||||
|
AuthenticationInfo(AuthenticationInfoRep* rep) : _rep(rep)
|
||||||
|
--- pegasus/src/Pegasus/Common/HTTPConnection.cpp.local-or-remote-auth 2006-02-28 21:21:37.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Common/HTTPConnection.cpp 2006-04-05 20:35:40.000000000 -0400
|
||||||
|
@@ -1828,6 +1828,30 @@
|
||||||
|
"_requestCount = %d", _requestCount.get());
|
||||||
|
message->dest = _outputMessageQueue->getQueueId();
|
||||||
|
// SendForget(message);
|
||||||
|
+
|
||||||
|
+ // Allow authenticators to differentiate Remote and Local users:
|
||||||
|
+ struct sockaddr_in sin_peer, sin_svr; // don't need to worry about IPv6 yet ...
|
||||||
|
+ socklen_t slen1=sizeof(struct sockaddr_in), slen2=sizeof(struct sockaddr_in);
|
||||||
|
+ uint32_t sock = _socket.get()->getSocket() ;
|
||||||
|
+ memset(&sin_peer,'\0',slen1);
|
||||||
|
+ memset(&sin_svr, '\0',slen2);
|
||||||
|
+ if ( ( ::getpeername( sock, (struct sockaddr*)&sin_peer, &slen1) == 0 )
|
||||||
|
+ ||( ::getsockname( sock, (struct sockaddr*)&sin_svr, &slen2) == 0 )
|
||||||
|
+ )
|
||||||
|
+ {
|
||||||
|
+ if( sin_peer.sin_family == AF_INET )
|
||||||
|
+ {
|
||||||
|
+ if( ((ntohl( sin_peer.sin_addr.s_addr ) >> 24) & 0xff) == 127 )
|
||||||
|
+ // message was sent FROM localhost interface
|
||||||
|
+ message->fromRemoteHost = false;
|
||||||
|
+ }
|
||||||
|
+ if( sin_svr.sin_family == AF_INET )
|
||||||
|
+ {
|
||||||
|
+ if( ((ntohl( sin_svr.sin_addr.s_addr ) >> 24) & 0xff) == 127 )
|
||||||
|
+ // message was sent TO localhost interface
|
||||||
|
+ message->fromRemoteHost = false;
|
||||||
|
+ }
|
||||||
|
+ }
|
||||||
|
|
||||||
|
//
|
||||||
|
// Set the entry status to BUSY.
|
||||||
|
--- pegasus/src/Pegasus/Common/AuthenticationInfoRep.h.local-or-remote-auth 2006-01-30 11:16:46.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Common/AuthenticationInfoRep.h 2006-04-05 20:37:59.000000000 -0400
|
||||||
|
@@ -143,6 +143,14 @@
|
||||||
|
|
||||||
|
void setExportConnection(Boolean exportConnection);
|
||||||
|
|
||||||
|
+ Boolean isRemoteUser() const
|
||||||
|
+ {
|
||||||
|
+ return _remoteUser;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ void setRemoteUser(Boolean remoteUser);
|
||||||
|
+
|
||||||
|
+
|
||||||
|
//PEP187
|
||||||
|
Array<SSLCertificateInfo*> getClientCertificateChain()
|
||||||
|
{
|
||||||
|
@@ -173,7 +181,8 @@
|
||||||
|
#endif
|
||||||
|
|
||||||
|
Boolean _exportConnection;
|
||||||
|
- Array<SSLCertificateInfo*> _clientCertificate;
|
||||||
|
+ Array<SSLCertificateInfo*> _clientCertificate;
|
||||||
|
+ Boolean _remoteUser;
|
||||||
|
};
|
||||||
|
|
||||||
|
PEGASUS_NAMESPACE_END
|
||||||
|
--- pegasus/src/Pegasus/Common/HTTPMessage.h.local-or-remote-auth 2006-01-30 11:17:04.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Common/HTTPMessage.h 2006-04-05 20:35:40.000000000 -0400
|
||||||
|
@@ -80,7 +80,8 @@
|
||||||
|
ContentLanguageList contentLanguages;
|
||||||
|
Boolean acceptLanguagesDecoded;
|
||||||
|
Boolean contentLanguagesDecoded;
|
||||||
|
- CIMException cimException;
|
||||||
|
+ Boolean fromRemoteHost;
|
||||||
|
+ CIMException cimException;
|
||||||
|
|
||||||
|
void parse(
|
||||||
|
String& startLine,
|
57
pegasus-2.5.1-no-rpath.patch
Normal file
57
pegasus-2.5.1-no-rpath.patch
Normal file
@ -0,0 +1,57 @@
|
|||||||
|
--- pegasus/mak/library-unix.mak.no-rpath 2006-01-30 11:16:23.000000000 -0500
|
||||||
|
+++ pegasus/mak/library-unix.mak 2006-04-05 19:31:23.000000000 -0400
|
||||||
|
@@ -81,14 +81,14 @@
|
||||||
|
ifneq ($(PEGASUS_PLATFORM),DARWIN_PPC_GNU)
|
||||||
|
ifdef PEGASUS_USE_RELEASE_DIRS
|
||||||
|
LINK_COMMAND = $(CXX) -shared $(LINK_MACHINE_OPTIONS)
|
||||||
|
- LINK_ARGUMENTS = -Wl,-hlib$(LIBRARY)$(LIB_SUFFIX) -Xlinker -rpath -Xlinker $(PEGASUS_DEST_LIB_DIR)
|
||||||
|
+ LINK_ARGUMENTS = -Wl,-hlib$(LIBRARY)$(LIB_SUFFIX) $(EXTRA_LINK_ARGUMENTS)
|
||||||
|
else
|
||||||
|
LINK_COMMAND = $(CXX) -shared $(LINK_MACHINE_OPTIONS)
|
||||||
|
- LINK_ARGUMENTS = -Wl,-hlib$(LIBRARY)$(LIB_SUFFIX) -Xlinker -rpath -Xlinker $(LIB_DIR) $(EXTRA_LINK_ARGUMENTS)
|
||||||
|
+ LINK_ARGUMENTS = -Wl,-hlib$(LIBRARY)$(LIB_SUFFIX) $(EXTRA_LINK_ARGUMENTS)
|
||||||
|
endif
|
||||||
|
else
|
||||||
|
LINK_COMMAND = $(CXX) -dynamiclib
|
||||||
|
- LINK_ARGUMENTS = --helplib$(LIBRARY)$(LIB_SUFFIX) -ldl
|
||||||
|
+ LINK_ARGUMENTS = --helplib$(LIBRARY)$(LIB_SUFFIX) -ldl $(EXTRA_LINK_ARGUMENTS)
|
||||||
|
endif
|
||||||
|
ifeq ($(PEGASUS_PLATFORM), SOLARIS_SPARC_GNU)
|
||||||
|
LINK_ARGUMENTS = -Wl,-hlib$(LIBRARY)$(LIB_SUFFIX) -Xlinker -L$(LIB_DIR) $(EXTRA_LINK_ARGUMENTS)
|
||||||
|
--- pegasus/mak/program-unix.mak.no-rpath 2006-01-30 11:16:23.000000000 -0500
|
||||||
|
+++ pegasus/mak/program-unix.mak 2006-04-05 19:41:59.000000000 -0400
|
||||||
|
@@ -30,22 +30,12 @@
|
||||||
|
#//==============================================================================
|
||||||
|
INCLUDES = -I$(ROOT)/src $(EXTRA_INCLUDES)
|
||||||
|
|
||||||
|
-ifndef LINK_RPATH
|
||||||
|
- LINK_RPATH = -Xlinker -rpath
|
||||||
|
-endif
|
||||||
|
-
|
||||||
|
LINK_DEST_LIB = -Xlinker $(PEGASUS_DEST_LIB_DIR)
|
||||||
|
|
||||||
|
LINK_LIB_DIR = -Xlinker $(LIB_DIR)
|
||||||
|
|
||||||
|
LINK_ICU = -Xlinker ${ICU_INSTALL}/lib
|
||||||
|
|
||||||
|
-ifndef LINK_RPATH_LINK
|
||||||
|
- LINK_RPATH_LINK = -Xlinker -rpath-link
|
||||||
|
-endif
|
||||||
|
-
|
||||||
|
-
|
||||||
|
-
|
||||||
|
TMP_OBJECTS = $(foreach i,$(SOURCES),$(OBJ_DIR)/$i)
|
||||||
|
|
||||||
|
ifeq ($(OS_TYPE),windows)
|
||||||
|
@@ -118,9 +108,9 @@
|
||||||
|
endif
|
||||||
|
else
|
||||||
|
ifdef PEGASUS_USE_RELEASE_DIRS
|
||||||
|
- $(LINK_WRAPPER) $(CXX) $(FLAGS) $(EXTRA_LINK_FLAGS) $(LINK_RPATH) $(LINK_DEST_LIB) $(LINK_RPATH_LINK) $(LINK_LIB_DIR) -L$(LIB_DIR) $(EXE_OUTPUT) $(OBJECTS) $(DYNAMIC_LIBRARIES) $(SYS_LIBS)
|
||||||
|
+ $(LINK_WRAPPER) $(CXX) $(FLAGS) $(EXTRA_LINK_FLAGS) -L$(LIB_DIR) $(EXE_OUTPUT) $(OBJECTS) $(DYNAMIC_LIBRARIES) $(SYS_LIBS)
|
||||||
|
else
|
||||||
|
- $(LINK_WRAPPER) $(CXX) $(FLAGS) $(EXTRA_LINK_FLAGS) $(LINK_RPATH) $(LINK_LIB_DIR) -L$(LIB_DIR) $(EXE_OUTPUT) $(OBJECTS) $(DYNAMIC_LIBRARIES) $(SYS_LIBS)
|
||||||
|
+ $(LINK_WRAPPER) $(CXX) $(FLAGS) $(EXTRA_LINK_FLAGS) -L$(LIB_DIR) $(EXE_OUTPUT) $(OBJECTS) $(DYNAMIC_LIBRARIES) $(SYS_LIBS)
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
else
|
22
pegasus-2.5.1-pam-wbem.patch
Normal file
22
pegasus-2.5.1-pam-wbem.patch
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
--- pegasus/rpm/wbem.pam-wbem 2006-01-17 14:17:43.000000000 -0500
|
||||||
|
+++ pegasus/rpm/wbem 2006-04-05 19:26:46.000000000 -0400
|
||||||
|
@@ -1,13 +1,7 @@
|
||||||
|
#%PAM-1.0
|
||||||
|
-auth required $ISA/pam_env.so
|
||||||
|
-auth sufficient $ISA/pam_unix.so nullok
|
||||||
|
-auth required $ISA/pam_deny.so
|
||||||
|
-
|
||||||
|
-account required $ISA/pam_unix.so
|
||||||
|
-
|
||||||
|
-password required $ISA/pam_cracklib.so retry=3 type=
|
||||||
|
-password sufficient $ISA/pam_unix.so nullok use_authtok md5 shadow
|
||||||
|
-password required $ISA/pam_deny.so
|
||||||
|
-
|
||||||
|
-session required $ISA/pam_limits.so
|
||||||
|
-session required $ISA/pam_unix.so
|
||||||
|
+auth include system-auth
|
||||||
|
+account required pam_access.so accessfile=/etc/Pegasus/access.conf
|
||||||
|
+account include system-auth
|
||||||
|
+password include system-auth
|
||||||
|
+session include system-auth
|
||||||
|
+session required pam_loginuid.so
|
65
pegasus-2.5.1-redhat-config.patch
Normal file
65
pegasus-2.5.1-redhat-config.patch
Normal file
@ -0,0 +1,65 @@
|
|||||||
|
--- pegasus/env_var_Linux.status.redhat-config 2006-03-15 20:33:51.000000000 -0500
|
||||||
|
+++ pegasus/env_var_Linux.status 2006-04-06 19:15:13.000000000 -0400
|
||||||
|
@@ -18,7 +18,7 @@
|
||||||
|
PEGASUS_STAGING_DIR = $(PEGASUS_HOME)/stagingDir
|
||||||
|
endif
|
||||||
|
|
||||||
|
-PEGASUS_DISABLE_CQL=true
|
||||||
|
+PEGASUS_ENABLE_CQL=true
|
||||||
|
PEGASUS_DISABLE_OBJECT_NORMALIZATION=true
|
||||||
|
PEGASUS_DISABLE_PERFINST=yes
|
||||||
|
PEGASUS_ENABLE_CMPI_PROVIDER_MANAGER=true
|
||||||
|
@@ -26,7 +26,6 @@
|
||||||
|
PEGASUS_HAS_SSL=yes
|
||||||
|
PEGASUS_NOASSERTS=yes
|
||||||
|
PEGASUS_PAM_AUTHENTICATION=true
|
||||||
|
-PEGASUS_USE_PAM_STANDALONE_PROC=true
|
||||||
|
PEGASUS_USE_RELEASE_CONFIG_OPTIONS=true
|
||||||
|
PEGASUS_USE_RELEASE_DIRS=true
|
||||||
|
PEGASUS_USE_SYSLOGS=true
|
||||||
|
@@ -64,18 +63,17 @@
|
||||||
|
PEGASUS_LOCAL_AUTH_DIR = $(PEGASUS_VARDATA_CACHE_DIR)/localauth
|
||||||
|
PEGASUS_TRACE_DIR = $(PEGASUS_VARDATA_CACHE_DIR)/trace
|
||||||
|
PEGASUS_TRACE_FILE_PATH = $(PEGASUS_VARDATA_CACHE_DIR)/trace/cimserver.trc
|
||||||
|
+PEGASUS_CONFIG_DIR = /etc/Pegasus
|
||||||
|
PEGASUS_PLANNED_CONFIG_FILE = cimserver_planned.conf
|
||||||
|
PEGASUS_PLANNED_CONFIG_FILE_PATH = \
|
||||||
|
- $(PEGASUS_VARDATA_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)
|
||||||
|
+ $(PEGASUS_CONFIG_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)
|
||||||
|
PEGASUS_CURRENT_CONFIG_FILE = cimserver_current.conf
|
||||||
|
PEGASUS_CURRENT_CONFIG_FILE_PATH = \
|
||||||
|
- $(PEGASUS_VARDATA_DIR)/$(PEGASUS_CURRENT_CONFIG_FILE)
|
||||||
|
+ $(PEGASUS_CONFIG_DIR)/$(PEGASUS_CURRENT_CONFIG_FILE)
|
||||||
|
|
||||||
|
PEGASUS_LOG_DIR = $(PEGASUS_VARDATA_DIR)/log
|
||||||
|
PEGASUS_INSTALL_LOG = $(PEGASUS_LOG_DIR)/install.log
|
||||||
|
|
||||||
|
-PEGASUS_CONFIG_DIR = /etc/Pegasus
|
||||||
|
-
|
||||||
|
PEGASUS_VARRUN_DIR = /var/run/tog-pegasus
|
||||||
|
PEGASUS_CIMSERVER_START_FILE = $(PEGASUS_VARRUN_DIR)/cimserver.pid
|
||||||
|
CIMSERVER_LOCK_FILE = $(PEGASUS_VARRUN_DIR)/cimserver_start.lock
|
||||||
|
--- pegasus/Makefile.Release.redhat-config 2006-01-30 11:16:16.000000000 -0500
|
||||||
|
+++ pegasus/Makefile.Release 2006-04-06 20:14:11.000000000 -0400
|
||||||
|
@@ -590,10 +590,10 @@
|
||||||
|
$(foreach i, $(MANAGEDSYSTEM_MOF_FILES), $(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Pr__r__r__)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PEGASUS_MOF_DIR)/Pegasus/$(i);)
|
||||||
|
|
||||||
|
stage_PegasusVarDataDirectoryFiles: FORCE
|
||||||
|
- $(COPY) $(ROOT)/src/Server/cimserver_planned.conf $(PEGASUS_STAGING_DIR)$(PEGASUS_VARDATA_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)
|
||||||
|
+ $(COPY) $(ROOT)/src/Server/cimserver_planned.conf $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)
|
||||||
|
|
||||||
|
setpermissions_PegasusVarDataDirectoryFiles: FORCE
|
||||||
|
- $(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Pr________)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PEGASUS_VARDATA_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)
|
||||||
|
+ $(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Pr________)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)
|
||||||
|
|
||||||
|
stage_genOpenPegasusSSLCertsFile: FORCE
|
||||||
|
@$(RM) $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
|
||||||
|
@@ -1233,7 +1233,7 @@
|
||||||
|
@$(ECHO-E) "%config %attr($(Prwxr_x___),$(INSTALL_USR),$(INSTALL_GRP))"\
|
||||||
|
"/etc/init.d/tog-pegasus" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
|
||||||
|
@$(ECHO-E) "%config(noreplace)" \
|
||||||
|
- "$(PEGASUS_VARDATA_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)" \
|
||||||
|
+ "$(PEGASUS_CONFIG_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)" \
|
||||||
|
>> $(PEGASUS_RPM_SPEC_FILE_PATH)
|
||||||
|
@$(ECHO-E) "%config(noreplace) $(PEGASUS_CONFIG_DIR)/access.conf" \
|
||||||
|
>> $(PEGASUS_RPM_SPEC_FILE_PATH)
|
117
pegasus-2.5.1-warnings.patch
Normal file
117
pegasus-2.5.1-warnings.patch
Normal file
@ -0,0 +1,117 @@
|
|||||||
|
--- pegasus/src/Pegasus/ProviderManager2/CMPI/CMPIProviderManager.cpp.warnings 2006-02-28 14:53:30.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/ProviderManager2/CMPI/CMPIProviderManager.cpp 2006-04-05 19:27:27.000000000 -0400
|
||||||
|
@@ -88,7 +88,7 @@
|
||||||
|
char **props;
|
||||||
|
int pCount;
|
||||||
|
public:
|
||||||
|
- CMPIPropertyList(CIMPropertyList &propertyList) {
|
||||||
|
+ CMPIPropertyList(CIMPropertyList &propertyList) : props(0L), pCount(0) {
|
||||||
|
if (!propertyList.isNull()) {
|
||||||
|
Array<CIMName> p=propertyList.getPropertyNameArray();
|
||||||
|
pCount=p.size();
|
||||||
|
@@ -2497,7 +2497,7 @@
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
- indProvRecord *provRec;
|
||||||
|
+ indProvRecord *provRec = 0L;
|
||||||
|
if (provTab.lookup (ph.GetProvider ().getName (), provRec))
|
||||||
|
{
|
||||||
|
provRec->enabled = true;
|
||||||
|
@@ -2587,7 +2587,7 @@
|
||||||
|
PEG_METHOD_ENTER (TRC_PROVIDERMANAGER,
|
||||||
|
"CMPIProviderManager::_callDisableIndications");
|
||||||
|
|
||||||
|
- indProvRecord * provRec;
|
||||||
|
+ indProvRecord * provRec = 0L;
|
||||||
|
if (provTab.lookup (ph.GetProvider ().getName (), provRec))
|
||||||
|
{
|
||||||
|
provRec->enabled = false;
|
||||||
|
--- pegasus/src/Pegasus/Config/ConfigManager.cpp.warnings 2006-03-14 16:06:37.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Config/ConfigManager.cpp 2006-04-05 19:27:27.000000000 -0400
|
||||||
|
@@ -758,7 +758,7 @@
|
||||||
|
//
|
||||||
|
for (Uint32 i = 0; i < NUM_PROPERTIES; i++)
|
||||||
|
{
|
||||||
|
- const char* fixedValue;
|
||||||
|
+ const char* fixedValue = 0L;
|
||||||
|
|
||||||
|
_properties[i].propertyOwner->initialize();
|
||||||
|
|
||||||
|
--- pegasus/src/Pegasus/Common/Packer.h.warnings 2006-01-30 11:17:07.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Common/Packer.h 2006-04-05 19:27:27.000000000 -0400
|
||||||
|
@@ -173,12 +173,12 @@
|
||||||
|
|
||||||
|
inline void Packer::packReal32(Buffer& out, Real32 x)
|
||||||
|
{
|
||||||
|
- packUint32(out, *((Uint32*)&x));
|
||||||
|
+ packUint32(out, (Uint32)x);
|
||||||
|
}
|
||||||
|
|
||||||
|
inline void Packer::packReal64(Buffer& out, Real64 x)
|
||||||
|
{
|
||||||
|
- packUint64(out, *((Uint64*)&x));
|
||||||
|
+ packUint64(out, (Uint64)x);
|
||||||
|
}
|
||||||
|
|
||||||
|
inline void Packer::packChar16(Buffer& out, Char16 x)
|
||||||
|
--- pegasus/src/Pegasus/Common/StringInline.h.warnings 2006-01-30 11:17:08.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Common/StringInline.h 2006-04-05 19:30:43.000000000 -0400
|
||||||
|
@@ -102,7 +102,7 @@
|
||||||
|
|
||||||
|
PEGASUS_STRING_INLINE const Char16* String::getChar16Data() const
|
||||||
|
{
|
||||||
|
- return (Char16*)_rep->data;
|
||||||
|
+ return (Char16*)&(_rep->data[0]);
|
||||||
|
}
|
||||||
|
|
||||||
|
PEGASUS_STRING_INLINE Char16& String::operator[](Uint32 i)
|
||||||
|
@@ -145,7 +145,7 @@
|
||||||
|
|
||||||
|
PEGASUS_STRING_INLINE Uint32 String::find(const String& s) const
|
||||||
|
{
|
||||||
|
- return StringFindAux(_rep, (Char16*)s._rep->data, s._rep->size);
|
||||||
|
+ return StringFindAux(_rep, (Char16*)&(s._rep->data[0]), s._rep->size);
|
||||||
|
}
|
||||||
|
|
||||||
|
PEGASUS_STRING_INLINE String& String::append(const Char16& c)
|
||||||
|
--- pegasus/src/Pegasus/Common/ResponseHandler.cpp.warnings 2006-01-30 11:17:07.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Common/ResponseHandler.cpp 2006-04-05 19:27:27.000000000 -0400
|
||||||
|
@@ -79,7 +79,7 @@
|
||||||
|
ResponseHandlerRep* _getRep(
|
||||||
|
const ResponseHandler* object)
|
||||||
|
{
|
||||||
|
- ResponseHandlerRep* rep;
|
||||||
|
+ ResponseHandlerRep* rep = 0L;
|
||||||
|
Boolean found;
|
||||||
|
|
||||||
|
AutoMutex lock(repTableMutex);
|
||||||
|
@@ -91,7 +91,7 @@
|
||||||
|
void _deleteRep(
|
||||||
|
ResponseHandler* object)
|
||||||
|
{
|
||||||
|
- ResponseHandlerRep* rep;
|
||||||
|
+ ResponseHandlerRep* rep = 0L;
|
||||||
|
Boolean found;
|
||||||
|
|
||||||
|
AutoMutex lock(repTableMutex);
|
||||||
|
--- pegasus/src/Pegasus/Common/String.cpp.warnings 2006-01-30 11:17:08.000000000 -0500
|
||||||
|
+++ pegasus/src/Pegasus/Common/String.cpp 2006-04-05 19:27:27.000000000 -0400
|
||||||
|
@@ -843,7 +843,7 @@
|
||||||
|
|
||||||
|
String& String::append(const String& str)
|
||||||
|
{
|
||||||
|
- return append((Char16*)str._rep->data, str._rep->size);
|
||||||
|
+ return append((Char16*)(&(str._rep->data[0])), str._rep->size);
|
||||||
|
}
|
||||||
|
|
||||||
|
String& String::append(const char* str, Uint32 size)
|
||||||
|
@@ -905,7 +905,7 @@
|
||||||
|
if (n == PEG_NOT_FOUND || n > _rep->size - index)
|
||||||
|
n = _rep->size - index;
|
||||||
|
|
||||||
|
- return String((Char16*)_rep->data + index, n);
|
||||||
|
+ return String((Char16*)(_rep->data + index), n);
|
||||||
|
}
|
||||||
|
|
||||||
|
return String();
|
69
pegasus_rpm_build_env.sh
Normal file
69
pegasus_rpm_build_env.sh
Normal file
@ -0,0 +1,69 @@
|
|||||||
|
# pegasus_rpm_build_env.sh:
|
||||||
|
#
|
||||||
|
# Open Pegasus RPM %build + %install environment setup.
|
||||||
|
#
|
||||||
|
# Expects these variables to be set on entry:
|
||||||
|
# RPM_ARCH : rpmbuild architecture identifier
|
||||||
|
# RPM_OPT_FLAGS : rpmbuild compile options
|
||||||
|
# RPM_BUILD_DIR : rpmbuild source directory
|
||||||
|
# RPM_BUILD_ROOT: rpmbuild build destination directory
|
||||||
|
# RPM_ARCH_LIB : %{_lib} : lib or lib64
|
||||||
|
# SRCNAME : name of pegasus source directory
|
||||||
|
#
|
||||||
|
# compile options:
|
||||||
|
#
|
||||||
|
export PEGASUS_EXTRA_C_FLAGS="$RPM_OPT_FLAGS -Wno-unused"
|
||||||
|
export PEGASUS_EXTRA_CXX_FLAGS="$PEGASUS_EXTRA_C_FLAGS"
|
||||||
|
export PEGASUS_EXTRA_PROGRAM_LINK_FLAGS="-pie -Wl,-z,relro,-z,now,-z,nodlopen,-z,noexecstack"
|
||||||
|
export SYS_INCLUDES=-I/usr/kerberos/include
|
||||||
|
#
|
||||||
|
# build object directories:
|
||||||
|
#
|
||||||
|
SRCNAME=${SRCNAME:-pegasus}
|
||||||
|
export PEGASUS_ROOT=${RPM_BUILD_DIR}/${SRCNAME}
|
||||||
|
export PEGASUS_HOME=${RPM_BUILD_DIR}/${SRCNAME}/build
|
||||||
|
#
|
||||||
|
# build time settings:
|
||||||
|
export PEGASUS_ARCH_LIB=${RPM_ARCH_LIB:-lib}
|
||||||
|
export PEGASUS_ENVVAR_FILE=${PEGASUS_ROOT}/env_var_Linux.status
|
||||||
|
export OPENSSL_HOME=/usr
|
||||||
|
export OPENSSL_BIN=/usr/bin
|
||||||
|
export LD_LIBRARY_PATH=${PEGASUS_HOME}/lib
|
||||||
|
export PATH=${PEGASUS_HOME}/bin:${PATH}
|
||||||
|
#
|
||||||
|
# PEGASUS_PLATFORM (hardware platform) setup:
|
||||||
|
#
|
||||||
|
if [ -z "$RPM_ARCH" ]; then
|
||||||
|
export RPM_ARCH=`/bin/uname -i`;
|
||||||
|
fi;
|
||||||
|
case ${RPM_ARCH} in
|
||||||
|
ia64)
|
||||||
|
export PEGASUS_PLATFORM=LINUX_IA64_GNU;
|
||||||
|
;;
|
||||||
|
x86_64)
|
||||||
|
export PEGASUS_PLATFORM=LINUX_X86_64_GNU;
|
||||||
|
;;
|
||||||
|
ppc)
|
||||||
|
export PEGASUS_PLATFORM=LINUX_PPC_GNU;
|
||||||
|
;;
|
||||||
|
ppc64|pseries)
|
||||||
|
export PEGASUS_PLATFORM=LINUX_PPC64_GNU;
|
||||||
|
;;
|
||||||
|
s390)
|
||||||
|
export PEGASUS_PLATFORM=LINUX_ZSERIES_GNU;
|
||||||
|
export PEGASUS_EXTRA_C_FLAGS="$PEGASUS_EXTRA_C_FLAGS -fsigned-char";
|
||||||
|
export PEGASUS_EXTRA_CXX_FLAGS="$PEGASUS_EXTRA_C_FLAGS";
|
||||||
|
;;
|
||||||
|
s390x|zseries)
|
||||||
|
export PEGASUS_PLATFORM=LINUX_ZSERIES64_GNU;
|
||||||
|
export PEGASUS_EXTRA_C_FLAGS="$PEGASUS_EXTRA_C_FLAGS -fsigned-char";
|
||||||
|
export PEGASUS_EXTRA_CXX_FLAGS="$PEGASUS_EXTRA_C_FLAGS";
|
||||||
|
;;
|
||||||
|
i386)
|
||||||
|
export PEGASUS_PLATFORM=LINUX_IX86_GNU
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo "Architecture unsupported by pegasus: $RPM_ARCH";
|
||||||
|
exit 1;
|
||||||
|
;;
|
||||||
|
esac;
|
2
sources
2
sources
@ -1 +1 @@
|
|||||||
0b068fd576f199f8a0946e2f659acfe4 pegasus-2.5.tar.gz
|
b7b392d2ff7ba9a4a3b8d7722d47314b pegasus-2.5.1.tar.gz
|
||||||
|
@ -141,6 +141,7 @@ make -f $PEGASUS_ROOT/Makefile.Release all
|
|||||||
make -f $PEGASUS_ROOT/Makefile.Release repository
|
make -f $PEGASUS_ROOT/Makefile.Release repository
|
||||||
|
|
||||||
%install
|
%install
|
||||||
|
export RPM_ARCH_LIB=%{_lib}
|
||||||
. %SOURCE1
|
. %SOURCE1
|
||||||
export PEGASUS_STAGING_DIR=$RPM_BUILD_ROOT;
|
export PEGASUS_STAGING_DIR=$RPM_BUILD_ROOT;
|
||||||
%if %{PEGASUS_BUILD_TEST_RPM}
|
%if %{PEGASUS_BUILD_TEST_RPM}
|
||||||
@ -216,7 +217,7 @@ rm -rf ${RPM_BUILD_ROOT}/usr/share/doc/%{name}-2.5
|
|||||||
%clean
|
%clean
|
||||||
%if !%{NOCLEAN}
|
%if !%{NOCLEAN}
|
||||||
[ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf $RPM_BUILD_ROOT;
|
[ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf $RPM_BUILD_ROOT;
|
||||||
[ "${RPM_BUILD_DIR}" != "/" ] && rm -rf ${RPM_BUILD_DIR}/%{name}-%{version};
|
[ "${RPM_BUILD_DIR}" != "/" ] && rm -rf ${RPM_BUILD_DIR}/%{srcname};
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%pre
|
%pre
|
||||||
|
Loading…
Reference in New Issue
Block a user