Hello community,

here is the log from the commit of package fence-agents for openSUSE:Factory 
checked in at 2014-02-26 06:57:37
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/fence-agents (Old)
 and      /work/SRC/openSUSE:Factory/.fence-agents.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "fence-agents"

Changes:
--------
--- /work/SRC/openSUSE:Factory/fence-agents/fence-agents.changes        
2014-01-13 13:49:36.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.fence-agents.new/fence-agents.changes   
2014-02-26 06:57:38.000000000 +0100
@@ -1,0 +2,22 @@
+Tue Feb 18 10:00:55 UTC 2014 - [email protected]
+
+- Update to version 4.0.7
+
+  + support for firmware v1.40 for WTI (MPC series)
+  
+  + nss_wrapper used for fence_ilo was replaced by gnutls-cli
+
+  + --delay was not respected in fence_vmware_soap
+
+  + fabric fence agents have 'off' as default action
+
+  + fence_scsi now generates correct key on corosync clusters
+
+  + regression was found in fence_ipmilan where -P and -L were 
+    interchanged on command line
+    (there was no problem with long options and input from STDIN)
+  
+  + fence_vmware_soap now fails with proper error message when user does 
+    not have enough privileges 
+
+-------------------------------------------------------------------

Old:
----
  fence-agents-4.0.6.tar.xz

New:
----
  fence-agents-4.0.7.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ fence-agents.spec ++++++
--- /var/tmp/diff_new_pack.kSLT9N/_old  2014-02-26 06:57:39.000000000 +0100
+++ /var/tmp/diff_new_pack.kSLT9N/_new  2014-02-26 06:57:39.000000000 +0100
@@ -22,7 +22,7 @@
 Summary:        Fence Agents for Pacemaker from RHCS
 License:        GPL-2.0 and LGPL-2.1
 Group:          Productivity/Clustering/HA
-Version:        4.0.6
+Version:        4.0.7
 Release:        0
 Url:            http://git.fedorahosted.org/git/fence-agents.git
 Source0:        
https://fedorahosted.org/releases/f/e/fence-agents/%{name}-%{version}.tar.xz

++++++ fence-agents-4.0.6.tar.xz -> fence-agents-4.0.7.tar.xz ++++++
++++ 2494 lines of diff (skipped)
++++    retrying with extended exclude list
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/.tarball-version new/fence-agents-4.0.7/.tarball-version
--- old/fence-agents-4.0.6/.tarball-version     2014-01-10 14:05:27.000000000 
+0100
+++ new/fence-agents-4.0.7/.tarball-version     2014-02-17 16:25:49.000000000 
+0100
@@ -1 +1 @@
-4.0.6
+4.0.7
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/.version new/fence-agents-4.0.7/.version
--- old/fence-agents-4.0.6/.version     2014-01-10 14:05:26.000000000 +0100
+++ new/fence-agents-4.0.7/.version     2014-02-17 16:25:47.000000000 +0100
@@ -1 +1 @@
-4.0.6
+4.0.7
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/ChangeLog new/fence-agents-4.0.7/ChangeLog
--- old/fence-agents-4.0.6/ChangeLog    2014-01-10 14:05:27.000000000 +0100
+++ new/fence-agents-4.0.7/ChangeLog    2014-02-17 16:25:49.000000000 +0100
@@ -1,3 +1,51 @@
+2014-02-17  Marek 'marx' Grac  <[email protected]>
+
+       fence_vmware_soap: Unknown exception fixed
+       Resolves: rhbz#1018780
+
+       fence_ilo: Replacing nss_wrapper with gnutls-cli
+       SSLv2 was disabled in nss package (rhbz#1001841), ilo2 now supports 
also SSLv3
+       and it is possible to use standard tool for communication.
+
+       fence_ipmilan: Mismatch between device options and getopt arguments (-L 
/ -P)
+
+2014-01-29  Marek 'marx' Grac  <[email protected]>
+
+       fence_wti: Add support for firmware v1.40 (on MPC device)
+       Previously, named groups were tested only on firmware v1.43 (on NPS 
device).
+
+2014-01-27  Marek 'marx' Grac  <[email protected]>
+
+       fencing: Do not output duplicities in metadata
+       With DEPENDENCY_OPT it becomes possible that items in device_opt can 
occur multiple times easily as they
+       are added automatically (e.g. 'password' imports also 
'password_script'). This lead to a situation when
+       eveyrything works but XML metadata contains this item multiple times 
and metadata can not be used properly
+       by cluster stack.
+
+2014-01-23  Marek 'marx' Grac  <[email protected]>
+
+       fence_kdump: Add vendor-url to metadata
+       Resolves: rhbz#1022529
+
+       fence_scsi: Change path to corosync from /sbin to /usr/sbin
+       /sbin is just a symlink to /usr/bin - so it does not impact 
functionality
+
+2014-01-22  Marek 'marx' Grac  <[email protected]>
+
+       fence_scsi: Replace automatic key generation to work with corosync 
clusters instead of cman
+       Resolves: rhbz#994466
+
+       fencing: Fabric fence agents should have default action "off"
+       Previously, when you have run fence agent without -o XYZ, reboot was 
performed. Fabric fence agents do not have them
+       so fence agent fails. This update does not fix only this issue but also 
text --help and in manual pages.
+
+       Resolves: rhbz#1021392
+
+2014-01-10  Marek 'marx' Grac  <[email protected]>
+
+       fence_vmware_soap: --delay is not respected
+       Because fence agent do not use standard login process, support for the 
--delay has to be added.
+
 2014-01-10  Ondrej Mular  <[email protected]>
 
        fence_ipmilan: add long description
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/configure.ac new/fence-agents-4.0.7/configure.ac
--- old/fence-agents-4.0.6/configure.ac 2014-01-10 13:52:12.000000000 +0100
+++ new/fence-agents-4.0.7/configure.ac 2014-02-17 14:16:06.000000000 +0100
@@ -166,6 +166,7 @@
 ## path to 3rd-party binaries
 AC_PATH_PROG([IPMITOOL_PATH], [ipmitool], [/usr/bin/ipmitool])
 AC_PATH_PROG([AMTTOOL_PATH], [amttool], [/usr/bin/amttool])
+AC_PATH_PROG([GNUTLSCLI_PATH], [gnutlscli], [/usr/bin/gnutls-cli])
 ## do subst
 
 AC_SUBST([DEFAULT_CONFIG_DIR])
@@ -284,7 +285,6 @@
                 fence/agents/manual/Makefile
                 fence/agents/mcdata/Makefile
                 fence/agents/netio/Makefile
-                fence/agents/nss_wrapper/Makefile
                 fence/agents/rackswitch/Makefile
                 fence/agents/ovh/Makefile
                 fence/agents/rhevm/Makefile
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/fence/agents/Makefile.am 
new/fence-agents-4.0.7/fence/agents/Makefile.am
--- old/fence-agents-4.0.6/fence/agents/Makefile.am     2013-03-06 
15:14:11.000000000 +0100
+++ new/fence-agents-4.0.7/fence/agents/Makefile.am     2014-02-17 
14:15:44.000000000 +0100
@@ -1,5 +1,4 @@
 MAINTAINERCLEANFILES   = Makefile.in
 
 SUBDIRS                = lib \
-                         nss_wrapper \
                          $(AGENTS_LIST)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/fence/agents/ipmilan/fence_ipmilan.py 
new/fence-agents-4.0.7/fence/agents/ipmilan/fence_ipmilan.py
--- old/fence-agents-4.0.6/fence/agents/ipmilan/fence_ipmilan.py        
2014-01-10 13:52:48.000000000 +0100
+++ new/fence-agents-4.0.7/fence/agents/ipmilan/fence_ipmilan.py        
2014-02-17 13:59:34.000000000 +0100
@@ -113,9 +113,9 @@
 
 def define_new_opts():
     all_opt["lanplus"] = {
-        "getopt" : "L",
+        "getopt" : "P",
         "longopt" : "lanplus",
-        "help" : "-L, --lanplus                  Use Lanplus to improve 
security of connection",
+        "help" : "-P, --lanplus                  Use Lanplus to improve 
security of connection",
         "required" : "0",
         "default" : "0",
         "shortdesc" : "Use Lanplus to improve security of connection",
@@ -140,9 +140,9 @@
         "order": 1
         }
     all_opt["privlvl"] = {
-        "getopt" : "P:",
+        "getopt" : "L:",
         "longopt" : "privlvl",
-        "help" : "-P, --privlvl=[level]          Privilege level on IPMI 
device (callback|user|operator|administrator)",
+        "help" : "-L, --privlvl=[level]          Privilege level on IPMI 
device (callback|user|operator|administrator)",
         "required" : "0",
         "shortdesc" : "Privilege level on IPMI device",
         "default" : "administrator",
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/fence/agents/kdump/fence_kdump.c 
new/fence-agents-4.0.7/fence/agents/kdump/fence_kdump.c
--- old/fence-agents-4.0.6/fence/agents/kdump/fence_kdump.c     2013-03-06 
15:14:11.000000000 +0100
+++ new/fence-agents-4.0.7/fence/agents/kdump/fence_kdump.c     2014-02-17 
13:59:34.000000000 +0100
@@ -178,6 +178,7 @@
     fprintf (stdout, "<longdesc>");
     fprintf (stdout, "The fence_kdump agent is intended to be used with with 
kdump service.");
     fprintf (stdout, "</longdesc>\n");
+    fprintf (stdout, 
"<vendor-url>http://www.kernel.org/pub/linux/utils/kernel/kexec/</vendor-url>\n");
 
     fprintf (stdout, "<parameters>\n");
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/fence/agents/lib/fencing.py.py 
new/fence-agents-4.0.7/fence/agents/lib/fencing.py.py
--- old/fence-agents-4.0.6/fence/agents/lib/fencing.py.py       2014-01-10 
13:52:42.000000000 +0100
+++ new/fence-agents-4.0.7/fence/agents/lib/fencing.py.py       2014-02-17 
14:09:28.000000000 +0100
@@ -28,7 +28,7 @@
 
 TELNET_PATH = "/usr/bin/telnet"
 SSH_PATH    = "/usr/bin/ssh"
-SSL_PATH    = "@LIBEXECDIR@/fence_nss_wrapper"
+SSL_PATH    = "@GNUTLSCLI_PATH@"
 SUDO_PATH   = "/usr/bin/sudo"
 
 all_opt = {
@@ -440,7 +440,8 @@
                        print "   " + value["help"]
 
 def metadata(avail_opt, options, docs):
-       sorted_list = [ (key, all_opt[key]) for key in avail_opt ]
+       # avail_opt has to be unique, if there are duplicities then they should 
be removed
+       sorted_list = [ (key, all_opt[key]) for key in list(set(avail_opt)) ]
        sorted_list.sort(lambda x, y: cmp(x[1]["order"], y[1]["order"]))
 
        print "<?xml version=\"1.0\" ?>"
@@ -618,6 +619,10 @@
        else:
                all_opt["login"]["required"] = "0"
 
+       if device_opt.count("fabric_fencing"):
+               all_opt["action"]["default"] = "off"
+               all_opt["action"]["help"] = "-o, --action=[action]          
Action: status, off (default) or on"
+
        ## Set default values
        #####
        for opt in device_opt:
@@ -955,11 +960,10 @@
                re_pass  = re.compile("(password)|(pass phrase)", re.IGNORECASE)
 
                if options.has_key("--ssl"):
-                       command = '%s %s %s %s' % (SSL_PATH, force_ipvx, 
options["--ip"], options["--ipport"])
+                       command = '%s --insecure --crlf -p %s %s' % (SSL_PATH, 
options["--ipport"], options["--ip"])
                        try:
                                conn = fspawn(options, command)
                        except pexpect.ExceptionPexpect, ex:
-                               ## SSL telnet is part of the fencing package
                                sys.stderr.write(str(ex) + "\n")
                                syslog.syslog(syslog.LOG_ERR, str(ex))
                                sys.exit(EC_GENERIC_ERROR)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/fence/agents/nss_wrapper/Makefile.am 
new/fence-agents-4.0.7/fence/agents/nss_wrapper/Makefile.am
--- old/fence-agents-4.0.6/fence/agents/nss_wrapper/Makefile.am 2014-01-10 
13:52:12.000000000 +0100
+++ new/fence-agents-4.0.7/fence/agents/nss_wrapper/Makefile.am 1970-01-01 
01:00:00.000000000 +0100
@@ -1,7 +0,0 @@
-MAINTAINERCLEANFILES     = Makefile.in
-
-libexec_PROGRAMS          = fence_nss_wrapper
-
-fence_nss_wrapper_CFLAGS  = $(nss_CFLAGS) $(nspr_CFLAGS)
-
-fence_nss_wrapper_LDFLAGS = $(nss_LIBS) $(nspr_LIBS)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/fence/agents/nss_wrapper/fence_nss_wrapper.c 
new/fence-agents-4.0.7/fence/agents/nss_wrapper/fence_nss_wrapper.c
--- old/fence-agents-4.0.6/fence/agents/nss_wrapper/fence_nss_wrapper.c 
2013-03-06 15:14:11.000000000 +0100
+++ new/fence-agents-4.0.7/fence/agents/nss_wrapper/fence_nss_wrapper.c 
1970-01-01 01:00:00.000000000 +0100
@@ -1,484 +0,0 @@
-/** @file fence_nss_wrapper.c - Main source code of hobbit like tool with
-  support for NSS (SSL) connection.
-*/
-#include "clusterautoconfig.h"
-
-#include <stdio.h>
-#include <nss.h>
-#include <ssl.h>
-#include <prio.h>
-#include <prnetdb.h>
-#include <prerror.h>
-#include <prinit.h>
-#include <getopt.h>
-#include <libgen.h>
-
-/*---- CONSTANTS -------------*/
-
-/** Default operation = connect and telnet*/
-#define OPERATION_DEFAULT 0
-/** Operation display help*/
-#define OPERATION_HELP 1
-
-/** Default mode of connection. Try first found working address*/
-#define MODE_DEFAULT 3
-/** Use only IPv4*/
-#define MODE_IP4MODE 1
-/** Use only IPv6*/
-#define MODE_IP6MODE 2
-/** Use RAW mode - no change of \r and \n to \r\n*/
-#define MODE_RAW     4
-/** Use non-secure mode (without SSL, only pure socket)*/
-#define MODE_NO_SSL  8
-
-/*------ Functions ---------------*/
-
-/** Return port inserted in string. Fuction tests, if port is integer, and 
than return
-  integer value of string. Otherwise, it will use /etc/services.  On fail, it 
returns
-  port -1.
-  @param port_s Input port or service name
-  @return port number (converted with ntohs) on success, otherwise -1.
-*/
-static int return_port(char *port_s) {
-  char *end_c;
-  int res;
-  struct servent *serv;
-
-  res=strtol(port_s,&end_c,10);
-
-  if (*end_c=='\0') return res;
-
-  /*It's not number, so try service name*/
-  serv=getservbyname(port_s,NULL);
-
-  if (serv==NULL) return -1;
-
-  return ntohs(serv->s_port);
-}
-
-/** Hook handler for bad certificate (because we have no DB, EVERY certificate 
is bad).
-  Returned value is always SECSuccess = it's ok certificate.
-  @param arg NULL value
-  @param fd socket cased error
-  @return SECSuccess.
-*/
-static SECStatus nss_bad_cert_hook(void *arg,PRFileDesc *fd) {
-  return SECSuccess;
-}
-
-/** Display last NSPR/NSS error code and user readable message.
-*/
-static void print_nspr_error(void) {
-  fprintf(stderr,"Error (%d): 
%s\n",PR_GetError(),PR_ErrorToString(PR_GetError(),PR_LANGUAGE_I_DEFAULT));
-}
-
-/** Initialize NSS. NSS is initialized without DB and with
-  domnestic policy.
-  @return 1 on success, otherwise 0.
-*/
-static int init_nss(void) {
-  if ((NSS_NoDB_Init(NULL)!=SECSuccess) ||
-      (NSS_SetDomesticPolicy()!=SECSuccess)) {
-    print_nspr_error();
-
-    return 0;
-  }
-
-  SSL_ClearSessionCache();
-
-  return 1;
-}
-
-/** Create socket. If ssl is >0, socket is ssl enabled.
-  @param ssl Enable ssl (Client, SSL2+3, no TLS, compatible hello) if PR_TRUE, 
otherwise no.
-  @param ipv6 New socket will be IPv4 if this value is 0, otherwise it will be 
ipv6
-  @return NULL on error, otherwise socket.
-*/
-static PRFileDesc *create_socket(int ssl,int ipv6) {
-  PRFileDesc *res_socket;
-
-  res_socket=PR_OpenTCPSocket((ipv6?PR_AF_INET6:PR_AF_INET));
-  if (res_socket==NULL) {
-    print_nspr_error();
-
-    return NULL;
-  }
-
-  if (!ssl) return res_socket;
-
-  if (!(res_socket=SSL_ImportFD(NULL,res_socket))) {
-    print_nspr_error();
-
-    return NULL;
-  }
-
-  if ((SSL_OptionSet(res_socket,SSL_SECURITY,ssl)!=SECSuccess) ||
-      (SSL_OptionSet(res_socket,SSL_HANDSHAKE_AS_SERVER,PR_FALSE)!=SECSuccess) 
||
-      (SSL_OptionSet(res_socket,SSL_HANDSHAKE_AS_CLIENT,PR_TRUE)!=SECSuccess) 
||
-      (SSL_OptionSet(res_socket,SSL_ENABLE_SSL2,ssl)!=SECSuccess) ||
-      (SSL_OptionSet(res_socket,SSL_ENABLE_SSL3,ssl)!=SECSuccess) ||
-      (SSL_OptionSet(res_socket,SSL_ENABLE_TLS,PR_FALSE)!=SECSuccess) ||
-      (SSL_OptionSet(res_socket,SSL_V2_COMPATIBLE_HELLO,ssl)!=SECSuccess) ||
-      (SSL_SetPKCS11PinArg(res_socket,NULL)==-1) ||
-      
(SSL_AuthCertificateHook(res_socket,SSL_AuthCertificate,CERT_GetDefaultCertDB())!=SECSuccess)
 ||
-      (SSL_BadCertHook(res_socket,nss_bad_cert_hook,NULL)!=SECSuccess)) {
-    print_nspr_error();
-
-    if (PR_Close(res_socket)!=PR_SUCCESS) {
-      print_nspr_error();
-    }
-
-    return NULL;
-  }
-
-  return res_socket;
-}
-
-/** Create socket and connect to it.
-  @param hostname Hostname to connect
-  @param port Port name/number to connect
-  @param mode Connection mode. Bit-array of MODE_NO_SSL, MODE_IP6MODE, 
MODE_IP4MODE.
-  @return NULL on error, otherwise connected socket.
-*/
-static PRFileDesc *create_connected_socket(char *hostname,int port,int mode) {
-  PRAddrInfo *addr_info;
-  void *addr_iter;
-  PRNetAddr addr;
-  PRFileDesc *localsocket;
-  int can_exit,valid_socket;
-  PRUint16 af_spec;
-
-  localsocket=NULL;
-
-  addr_info=NULL;
-
-  af_spec=PR_AF_UNSPEC;
-
-  if (!(mode&MODE_IP6MODE)) af_spec=PR_AF_INET;
-
-  addr_info=PR_GetAddrInfoByName(hostname,af_spec,PR_AI_ADDRCONFIG);
-
-  if (addr_info == NULL) {
-    print_nspr_error();
-    return NULL;
-  }
-
-  /*We have socket -> enumerate and try to connect*/
-  addr_iter=NULL;
-  can_exit=0;
-  valid_socket=0;
-
-  while (!can_exit) {
-    addr_iter=PR_EnumerateAddrInfo(addr_iter,addr_info,port,&addr);
-
-    if (addr_iter==NULL) {
-      can_exit=1;
-    } else {
-      if ((PR_NetAddrFamily(&addr)==PR_AF_INET && (mode&MODE_IP4MODE)) ||
-          (PR_NetAddrFamily(&addr)==PR_AF_INET6 && (mode&MODE_IP6MODE))) {
-        /*Type of address is what user want, try to create socket and make 
connection*/
-
-        /*Create socket*/
-        
localsocket=create_socket(!(mode&MODE_NO_SSL),(PR_NetAddrFamily(&addr)==PR_AF_INET6));
-
-        if (localsocket) {
-          /*Try to connect*/
-          if 
(PR_Connect(localsocket,&addr,PR_INTERVAL_NO_TIMEOUT)==PR_SUCCESS) {
-            /*Force handshake*/
-            if ((!(mode&MODE_NO_SSL)) && 
SSL_ForceHandshake(localsocket)!=SECSuccess) {
-              /*Handhake failure -> fail*/
-              print_nspr_error();
-              if (PR_Close(localsocket)!=PR_SUCCESS) {
-                print_nspr_error();
-                can_exit=1;
-              }
-              localsocket=NULL;
-            }
-
-            /*Socket is connected -> we can return it*/
-            can_exit=1;
-          } else {
-            /*Try another address*/
-            if (PR_Close(localsocket)!=PR_SUCCESS) {
-              print_nspr_error();
-              can_exit=1;
-            }
-            localsocket=NULL;
-          }
-        }
-      }
-    }
-  }
-
-  if (!localsocket) {
-    /*Socket is unvalid -> we don't found any usable address*/
-    fprintf(stderr,"Can't connect to host %s on port %d!\n",hostname,port);
-  }
-
-  PR_FreeAddrInfo(addr_info);
-
-  return localsocket;
-}
-
-/** Parse arguments from command line.
-  @param argc Number of arguments in argv
-  @param argv Array of arguments
-  @param mode Pointer to int will be filled with OPERATION_DEFAULT or 
OPERATION_HELP.
-  @param mode Pointer to int will be filled with MODE_DEFAULT, MODE_IP4MODE or 
MODE_IP4MODE.
-  @return 1 on success, otherwise 0.
-*/
-static int parse_cli(int argc,char *argv[],int *operation,int *mode,char 
**hostname,char **port) {
-  int opt;
-
-  *operation=OPERATION_DEFAULT;
-  *mode=MODE_DEFAULT;
-  *port=NULL;
-  *hostname=NULL;
-
-  while ((opt=getopt(argc,argv,"h46rz"))!=-1) {
-    switch (opt) {
-      case 'h':
-        *operation=OPERATION_HELP;
-
-        return 0;
-      break;
-
-      case '4':
-        (*mode)&=~MODE_IP6MODE;
-        (*mode)|=MODE_IP4MODE;
-      break;
-
-      case '6':
-        (*mode)&=~MODE_IP4MODE;
-        (*mode)|=MODE_IP6MODE;
-      break;
-
-      case 'r':
-        (*mode)|=MODE_RAW;
-      break;
-
-      case 'z':
-        (*mode)|=MODE_NO_SSL;
-      break;
-
-      default:
-        return 0;
-      break;
-    }
-  }
-
-  if (argc-optind<2) {
-    fprintf(stderr,"Hostname and port is expected!\n");
-
-    return 0;
-  }
-
-  *hostname=argv[optind];
-  *port=argv[optind+1];
-
-  return 1;
-}
-
-/** Show usage of application.
-  @param pname Name of program (usually basename of argv[0])
-*/
-static void show_usage(char *pname) {
-  printf("usage: %s [options] hostname port\n", pname);
-  printf("   -4             Force to use IPv4\n");
-  printf("   -6             Force to use IPv6\n");
-  printf("   -r             Use RAW connection (don't convert \\r and \\n 
characters)\n");
-  printf("   -z             Don't use SSL connection (use pure socket)\n");
-  printf("   -h             Show this help\n");
-}
-
-/** Convert End Of Lines (Unix \n, Macs \r or DOS/Win \r\n) to \r\n.
-  @param in_buffer Input buffer
-  @param in_size Input buffer size
-  @param out_buffer Output buffer (must be prealocated). Should be (2*in_size) 
(in worst case)
-  @param out_size There will be size of out_buffer
-  @param in_state Internal state of finite automata. First call should have 
this 0, other calls
-    shouldn't change this value. After end of file, you may add to this value 
+100 and call this
-    again, to make sure of proper end (in_buffer can be in this case 
everything, including NULL).
-*/
-static void convert_eols(char *in_buffer,int in_size,char *out_buffer,int 
*out_size,int *in_state) {
-  int in_pos,out_pos;
-  int status;
-  char in_char;
-
-  out_pos=0;
-  status=*in_state;
-
-  if (status==100 || status==101) {
-    if (status==101) {
-      out_buffer[out_pos++]='\r';
-      out_buffer[out_pos++]='\n';
-    }
-  } else {
-    for (in_pos=0;in_pos<in_size;in_pos++) {
-      in_char=in_buffer[in_pos];
-
-      switch (status) {
-        case 0:
-          if (in_char=='\r') status=1;
-          if (in_char=='\n') {
-            out_buffer[out_pos++]='\r';
-            out_buffer[out_pos++]='\n';
-          }
-          if ((in_char!='\r') && (in_char!='\n')) 
out_buffer[out_pos++]=in_char;
-        break;
-
-        case 1:
-          out_buffer[out_pos++]='\r';
-          out_buffer[out_pos++]='\n';
-
-          if (in_char!='\n') out_buffer[out_pos++]=in_char;
-
-          status=0;
-        break;
-      }
-    }
-  }
-
-  *out_size=out_pos;
-  *in_state=status;
-}
-
-/** Start polling cycle.
-  @param socket Network connected socket.
-  @param mode Bit-array of MODE_*. This function take care on MODE_RAW.
-  @return 0 on failure, otherwise 1
-*/
-static int poll_cycle(PRFileDesc *localsocket,int mode) {
-  PRPollDesc pool[2];
-  char buffer[1024],buffer_eol[1024*2];
-  int readed_bytes;
-  int can_exit;
-  int res;
-  int bytes_to_write;
-  int eol_state;
-
-  can_exit=0;
-  eol_state=0;
-
-  /* Fill pool*/
-  pool[1].fd=localsocket;
-  pool[0].fd=PR_STDIN;
-  pool[0].in_flags=pool[1].in_flags=PR_POLL_READ;
-  pool[0].out_flags=pool[1].out_flags=0;
-
-  while (!can_exit) {
-    res=(PR_Poll(pool,sizeof(pool)/sizeof(PRPollDesc),PR_INTERVAL_NO_TIMEOUT));
-
-    if (res==-1) {
-      print_nspr_error();
-
-      return 0;
-    }
-
-    if (pool[1].out_flags&PR_POLL_READ) {
-      /*We have something in socket*/
-      if ((readed_bytes=PR_Read(pool[1].fd,buffer,sizeof(buffer)))>0) {
-        if (PR_Write(PR_STDOUT,buffer,readed_bytes)!=readed_bytes) {
-          print_nspr_error();
-
-          return 0;
-        }
-      } else {
-        /*End of stream -> quit*/
-        can_exit=1;
-      }
-    }
-
-    if (pool[0].out_flags&(PR_POLL_READ|PR_POLL_HUP)) {
-      /*We have something in stdin*/
-      if ((readed_bytes=PR_Read(pool[0].fd,buffer,sizeof(buffer)))>0) {
-
-        if (!(mode&MODE_RAW)) {
-          
convert_eols(buffer,readed_bytes,buffer_eol,&bytes_to_write,&eol_state);
-        } else
-          bytes_to_write=readed_bytes;
-
-        if 
(PR_Write(pool[1].fd,(mode&MODE_RAW?buffer:buffer_eol),bytes_to_write)!=bytes_to_write)
 {
-          print_nspr_error();
-
-          return 0;
-        }
-      } else {
-        /*End of stream -> send EOL (if needed)*/
-        if (!(mode&MODE_RAW)) {
-          eol_state+=100;
-          convert_eols(NULL,0,buffer_eol,&bytes_to_write,&eol_state);
-          if (PR_Write(pool[1].fd,buffer_eol,bytes_to_write)!=bytes_to_write) {
-            print_nspr_error();
-
-            return 0;
-          }
-        }
-      }
-    }
-
-    pool[0].out_flags=pool[1].out_flags=0;
-  } /*while (!can_exit)*/
-
-  return 1;
-}
-
-static void atexit_handler(void) {
-  if (PR_Initialized())
-    PR_Cleanup();
-
-  if (fclose(stdout)!=0) {
-    fprintf(stderr,"Can't close stdout!\n");
-
-    exit(1);
-  }
-}
-
-/** Entry point of application.
-  @param argc Number of arguments on command line
-  @param argv Array of strings with arguments from command line
-  @return 0 on success, otherwise >0.
-*/
-int main(int argc,char *argv[]) {
-  int mode,operation;
-  char *hostname, *port;
-  char *pname;
-  int port_n;
-  PRFileDesc *fd_socket;
-  int res;
-
-  pname=basename(argv[0]);
-
-  atexit(atexit_handler);
-
-  if (!parse_cli(argc,argv,&operation,&mode,&hostname,&port) || 
operation==OPERATION_HELP) {
-    show_usage(pname);
-
-    if (operation!=OPERATION_HELP) return 1;
-
-    return 0;
-  }
-
-  if ((port_n=return_port(port))==-1) {
-    fprintf(stderr,"Error. Unknown port number/name %s!\n",port);
-
-    return 1;
-  }
-
-  if (!(mode&MODE_NO_SSL)) {
-    if (!init_nss()) return 1;
-  }
-
-  if (!(fd_socket=create_connected_socket(hostname,port_n,mode)))
-    return 1;
-
-  res=poll_cycle(fd_socket,mode);
-
-  if (PR_Close(fd_socket)!=PR_SUCCESS) {
-    print_nspr_error();
-
-    return 1;
-  }
-
-  return (res?0:1);
-}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/fence/agents/scsi/fence_scsi.pl 
new/fence-agents-4.0.7/fence/agents/scsi/fence_scsi.pl
--- old/fence-agents-4.0.6/fence/agents/scsi/fence_scsi.pl      2014-01-10 
13:52:12.000000000 +0100
+++ new/fence-agents-4.0.7/fence/agents/scsi/fence_scsi.pl      2014-02-17 
13:59:34.000000000 +0100
@@ -5,6 +5,7 @@
 use File::Path;
 use Getopt::Std;
 use POSIX;
+use B;
 
 #BEGIN_VERSION_GENERATION
 $RELEASE_VERSION="";
@@ -426,10 +427,10 @@
 sub get_node_id ($)
 {
     my $self = (caller(0))[3];
-    my $node_id;
+    my $node = $_[0];
 
-    my $cmd = "cman_tool nodes -n $_[0] -F id";
-    my $out = qx { $cmd 2> /dev/null };
+    my $cmd = "/usr/sbin/corosync-cmapctl nodelist.";
+    my @out = qx { $cmd 2> /dev/null };
     my $err = ($?>>8);
 
     if ($err != 0) {
@@ -438,11 +439,14 @@
 
     # die "[error]: $self\n" if ($?>>8);
 
-    chomp ($out);
-
-    $node_id = $out;
-
-    return ($node_id);
+    foreach my $line (@out) {
+        chomp($line);
+        if ($line =~ /.(\d+?).ring._addr \(str\) = ${node}$/) {
+            return $1;
+        }
+    }
+                                        
+    log_error("$self (unable to parse output of corosync-cmapctl or node does 
not exist)");
 }
 
 sub get_cluster_id ()
@@ -450,8 +454,8 @@
     my $self = (caller(0))[3];
     my $cluster_id;
 
-    my $cmd = "cman_tool status";
-    my @out = qx { $cmd 2> /dev/null };
+    my $cmd = "/usr/sbin/corosync-cmapctl totem.cluster_name";
+    my $out = qx { $cmd 2> /dev/null };
     my $err = ($?>>8);
 
     if ($err != 0) {
@@ -460,12 +464,14 @@
 
     # die "[error]: $self\n" if ($?>>8);
 
-    foreach (@out) {
-       chomp;
-       my ($param, $value) = split (/\s*:\s*/, $_);
-       if ($param =~ /^cluster\s+id/i) {
-           $cluster_id = $value;
-       }
+    chomp($out);
+
+    if ($out =~ /=\s(.*?)$/) {
+        my $cluster_name = $1;
+        # tranform string to a number
+        $cluster_id = (hex B::hash($cluster_name)) % 65536;
+    } else {
+        log_error("$self (unable to parse output of corosync-cmapctl)");
     }
 
     return ($cluster_id);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/fence/agents/vmware_soap/fence_vmware_soap.py 
new/fence-agents-4.0.7/fence/agents/vmware_soap/fence_vmware_soap.py
--- old/fence-agents-4.0.6/fence/agents/vmware_soap/fence_vmware_soap.py        
2014-01-10 13:52:12.000000000 +0100
+++ new/fence-agents-4.0.7/fence/agents/vmware_soap/fence_vmware_soap.py        
2014-02-17 15:13:59.000000000 +0100
@@ -1,7 +1,7 @@
 #!/usr/bin/python
 
-import sys, exceptions
-import shutil, tempfile
+import sys, exceptions, time
+import shutil, tempfile, suds
 sys.path.append("@FENCEAGENTSLIBDIR@")
 
 from suds.client import Client
@@ -15,6 +15,9 @@
 #END_VERSION_GENERATION
 
 def soap_login(options):
+       if options["-o"] in ["off", "reboot"]:
+               time.sleep(int(options["--delay"]))
+
        if options.has_key("--ssl"):
                url = "https://";
        else:
@@ -161,7 +164,7 @@
                        conn.service.PowerOnVM_Task(mo_machine)
                else:
                        conn.service.PowerOffVM_Task(mo_machine)
-       except WebFault, ex:
+       except suds.WebFault, ex:
                if ((str(ex).find("Permission to perform this operation was 
denied")) >= 0):
                        fail(EC_INVALID_PRIVILEGES)
                else:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/fence/agents/wti/fence_wti.py 
new/fence-agents-4.0.7/fence/agents/wti/fence_wti.py
--- old/fence-agents-4.0.6/fence/agents/wti/fence_wti.py        2014-01-10 
13:52:12.000000000 +0100
+++ new/fence-agents-4.0.7/fence/agents/wti/fence_wti.py        2014-02-17 
13:59:34.000000000 +0100
@@ -96,12 +96,13 @@
                if (line.find("|") >= 0 and line.lstrip().startswith("GROUP 
NAME") == False):
                        plug_line = [x.strip().lower() for x in line.split("|")]
                        if ["list", "monitor"].count(options["--action"]) == 0 
and options["--plug"].lower() == plug_line[name_index]:
-                               line_index += 1
                                plug_status = []
                                while line_index < len(lines) and line_index >= 
0:
                                        plug_line = [x.strip().lower() for x in 
lines[line_index].split("|")]
-                                       if len(plug_line[plug_index]) > 0 and 
len(plug_line[name_index]) == 0:
-                                               
plug_status.append(plug_line[status_index])
+                                       if len(plug_line) >= max(name_index, 
status_index) and len(plug_line[plug_index]) > 0 and 
(len(plug_line[name_index]) == 0 or options["--plug"].lower() == 
plug_line[name_index]):
+                                               ## Firmware 1.43 does not have 
a valid value of plug on first line as only name is defined on that line
+                                               if not "---" in 
plug_line[status_index]:
+                                                       
plug_status.append(plug_line[status_index])
                                                line_index += 1
                                        else:
                                                line_index = -1
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/fence-agents-4.0.6/make/fencebuild.mk 
new/fence-agents-4.0.7/make/fencebuild.mk
--- old/fence-agents-4.0.6/make/fencebuild.mk   2014-01-10 13:52:12.000000000 
+0100
+++ new/fence-agents-4.0.7/make/fencebuild.mk   2014-02-17 14:05:05.000000000 
+0100
@@ -11,6 +11,7 @@
                -e 's#@''LIBEXECDIR@#${libexecdir}#g' \
                -e 's#@''IPMITOOL_PATH@#${IPMITOOL_PATH}#g' \
                -e 's#@''AMTTOOL_PATH@#${AMTTOOL_PATH}#g' \
+               -e 's#@''GNUTLSCLI_PATH@#${GNUTLSCLI_PATH}#g' \
        > $@
 
        if [ 0 -eq `echo "$(SRC)" | grep fence_ &> /dev/null; echo $$?` ]; then 
\

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to