You can subscribe to this list here.
2005 |
Jan
|
Feb
(1) |
Mar
(45) |
Apr
(150) |
May
(145) |
Jun
(150) |
Jul
(79) |
Aug
(313) |
Sep
(160) |
Oct
(309) |
Nov
(115) |
Dec
(60) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2006 |
Jan
(160) |
Feb
(144) |
Mar
(127) |
Apr
(48) |
May
(102) |
Jun
(54) |
Jul
(245) |
Aug
(94) |
Sep
(152) |
Oct
(162) |
Nov
(166) |
Dec
(740) |
2007 |
Jan
(752) |
Feb
(437) |
Mar
(328) |
Apr
(373) |
May
(569) |
Jun
(399) |
Jul
(369) |
Aug
(627) |
Sep
(100) |
Oct
(306) |
Nov
(166) |
Dec
(282) |
2008 |
Jan
(68) |
Feb
(145) |
Mar
(180) |
Apr
(160) |
May
(277) |
Jun
(229) |
Jul
(1188) |
Aug
(51) |
Sep
(97) |
Oct
(99) |
Nov
(95) |
Dec
(170) |
2009 |
Jan
(39) |
Feb
(73) |
Mar
(120) |
Apr
(121) |
May
(104) |
Jun
(262) |
Jul
(57) |
Aug
(171) |
Sep
(131) |
Oct
(88) |
Nov
(64) |
Dec
(83) |
2010 |
Jan
(55) |
Feb
(67) |
Mar
(124) |
Apr
(64) |
May
(130) |
Jun
(75) |
Jul
(164) |
Aug
(64) |
Sep
(44) |
Oct
(17) |
Nov
(43) |
Dec
(31) |
2011 |
Jan
(21) |
Feb
(10) |
Mar
(43) |
Apr
(46) |
May
(52) |
Jun
(71) |
Jul
(7) |
Aug
(16) |
Sep
(51) |
Oct
(14) |
Nov
(33) |
Dec
(15) |
2012 |
Jan
(12) |
Feb
(61) |
Mar
(129) |
Apr
(76) |
May
(70) |
Jun
(52) |
Jul
(29) |
Aug
(41) |
Sep
(32) |
Oct
(23) |
Nov
(38) |
Dec
(26) |
2013 |
Jan
(35) |
Feb
(37) |
Mar
(51) |
Apr
(15) |
May
(52) |
Jun
(15) |
Jul
(23) |
Aug
(21) |
Sep
(46) |
Oct
(69) |
Nov
(57) |
Dec
(26) |
2014 |
Jan
(5) |
Feb
(13) |
Mar
(17) |
Apr
(1) |
May
(5) |
Jun
|
Jul
(2) |
Aug
(2) |
Sep
(1) |
Oct
(16) |
Nov
(8) |
Dec
(4) |
2015 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
(1) |
Jun
(4) |
Jul
|
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
2016 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
From: Dave B. <bla...@us...> - 2013-11-12 16:42:29
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv2815/src/org/sblim/cimclient/internal/cimxml/sax/node Modified Files: Tag: Experimental InstanceNameNode.java Log Message: 2707 INSTANCENAME ignores KEYVALUE and VALUE.REFERENCE children Index: InstanceNameNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/InstanceNameNode.java,v retrieving revision 1.1.2.10 retrieving revision 1.1.2.11 diff -u -d -r1.1.2.10 -r1.1.2.11 --- InstanceNameNode.java 12 Nov 2013 16:32:20 -0000 1.1.2.10 +++ InstanceNameNode.java 12 Nov 2013 16:42:27 -0000 1.1.2.11 @@ -1,5 +1,5 @@ /** - * (C) Copyright IBM Corp. 2006, 2009 + * (C) Copyright IBM Corp. 2006, 2013 * * THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE * ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE |
From: Dave B. <bla...@us...> - 2013-11-12 16:32:23
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv2259/src/org/sblim/cimclient/internal/cimxml/sax/node Modified Files: Tag: Experimental InstanceNameNode.java Log Message: 2707 INSTANCENAME ignores KEYVALUE and VALUE.REFERENCE children Index: InstanceNameNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/InstanceNameNode.java,v retrieving revision 1.1.2.9 retrieving revision 1.1.2.10 diff -u -d -r1.1.2.9 -r1.1.2.10 --- InstanceNameNode.java 1 Jun 2009 17:01:10 -0000 1.1.2.9 +++ InstanceNameNode.java 12 Nov 2013 16:32:20 -0000 1.1.2.10 @@ -18,8 +18,9 @@ * 1720707 2007-05-17 ebak Conventional Node factory for CIM-XML SAX parser * 2003590 2008-06-30 blaschke-oss Change licensing from CPL to EPL * 2524131 2009-01-21 raman_arora Upgrade client to JDK 1.5 (Phase 1) - * 2531371 2009-02-10 raman_arora Upgrade client to JDK 1.5 (Phase 2) + * 2531371 2009-02-10 raman_arora Upgrade client to JDK 1.5 (Phase 2) * 2797550 2009-06-01 raman_arora JSR48 compliance - add Java Generics + * 2707 2013-11-12 blaschke-oss INSTANCENAME ignores KEYVALUE and VALUE.REFERENCE children */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -50,6 +51,8 @@ private CIMObjectPath iLocalPath; + private String iNodeName; + /** * Ctor. */ @@ -62,6 +65,7 @@ this.iLocalPath = pSession.getDefLocalPath(); if (this.iCIMPropAL != null) this.iCIMPropAL.clear(); this.iClassName = getClassName(pAttribs); + this.iNodeName = null; } /** @@ -72,17 +76,33 @@ // no data } + private static final String[] ALLOWED_CHILDREN = { KEYBINDING, KEYVALUE, VALUE_REFERENCE }; + @Override public void testChild(String pNodeNameEnum) throws SAXException { - if (pNodeNameEnum != KEYBINDING) throw new SAXException(getNodeName() - + " node can only have KEYBINDING child nodes! " + pNodeNameEnum - + " child node is not allowed!"); + for (int i = 0; i < ALLOWED_CHILDREN.length; i++) + if (ALLOWED_CHILDREN[i] == pNodeNameEnum) { + if (this.iNodeName != null && this.iNodeName != pNodeNameEnum) throw new SAXException( + getNodeName() + " node cannot have " + pNodeNameEnum + + " child node, it already has a " + this.iNodeName + "!"); + if (pNodeNameEnum != KEYBINDING) { + if (this.iNodeName != null) throw new SAXException(getNodeName() + + " node can have only one " + pNodeNameEnum + " child node!"); + } + this.iNodeName = pNodeNameEnum; + return; + } + throw new SAXException(getNodeName() + " node cannot have " + pNodeNameEnum + + " child node!"); } @Override public void childParsed(Node pChild) { if (this.iCIMPropAL == null) this.iCIMPropAL = new ArrayList<CIMProperty<?>>(); - this.iCIMPropAL.add(((KeyBindingNode) pChild).getCIMProperty()); + if (pChild instanceof KeyBindingNode) this.iCIMPropAL.add(((KeyBindingNode) pChild) + .getCIMProperty()); + else this.iCIMPropAL.add(new CIMProperty<Object>("", ((AbstractScalarValueNode) pChild) + .getType(), ((AbstractScalarValueNode) pChild).getValue(), true, false, null)); } @Override |
From: Dave B. <bla...@us...> - 2013-11-12 00:19:43
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv3828/src/org/sblim/cimclient/internal/cimxml/sax/node Modified Files: Tag: Experimental Node.java Log Message: 2706 Bad PARAMETER.REFARRAY ARRAYSIZE generates NumberFormatException Index: Node.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/Node.java,v retrieving revision 1.1.2.16 retrieving revision 1.1.2.17 diff -u -d -r1.1.2.16 -r1.1.2.17 --- Node.java 7 Nov 2013 22:40:16 -0000 1.1.2.16 +++ Node.java 12 Nov 2013 00:19:40 -0000 1.1.2.17 @@ -27,6 +27,7 @@ * 2605 2013-03-20 buccella SAX parser throws wrong exception * 2693 2013-10-21 blaschke-oss ReturnValueNode allows invalid PARAMTYPE attribute * 2702 2013-11-07 blaschke-oss Bad PROPERTY.ARRAY ARRAYSIZE generates NumberFormatException + * 2706 2013-11-11 blaschke-oss Bad PARAMETER.REFARRAY ARRAYSIZE generates NumberFormatException */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -224,7 +225,13 @@ public static int getArraySize(Attributes pAttribs) throws SAXException { String arraySizeStr = pAttribs.getValue("ARRAYSIZE"); // 0 - unbounded size - int size = arraySizeStr == null ? 0 : Integer.parseInt(arraySizeStr); + int size = 0; + try { + size = arraySizeStr == null || arraySizeStr.length() == 0 ? 0 : Integer + .parseInt(arraySizeStr); + } catch (NumberFormatException e) { + throw new SAXException(arraySizeStr + " is not a valid ARRAYSIZE attribute!"); + } if (size < 0) throw new SAXException("ARRAYSIZE cannot be " + size + "!"); return size; } |
From: Dave B. <bla...@us...> - 2013-11-11 22:56:39
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv29201/src/org/sblim/cimclient/internal/cimxml/sax/node Modified Files: Tag: Experimental ParameterArrayNode.java Log Message: 2705 PARAMETER.ARRAY does not require TYPE attribute Index: ParameterArrayNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/ParameterArrayNode.java,v retrieving revision 1.1.2.5 retrieving revision 1.1.2.6 diff -u -d -r1.1.2.5 -r1.1.2.6 --- ParameterArrayNode.java 23 Feb 2009 18:25:57 -0000 1.1.2.5 +++ ParameterArrayNode.java 11 Nov 2013 22:56:36 -0000 1.1.2.6 @@ -1,5 +1,5 @@ /** - * (C) Copyright IBM Corp. 2006, 2009 + * (C) Copyright IBM Corp. 2006, 2013 * * THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE * ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE @@ -17,6 +17,7 @@ * 1820763 2007-10-29 ebak Supporting the EmbeddedInstance qualifier * 2003590 2008-06-30 blaschke-oss Change licensing from CPL to EPL * 2524131 2009-01-21 raman_arora Upgrade client to JDK 1.5 (Phase 1) + * 2705 2013-11-11 blaschke-oss PARAMETER.ARRAY does not require TYPE attribute */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -51,6 +52,8 @@ @Override protected void specificInit(Attributes pAttribs) throws SAXException { + if (getCIMType(pAttribs, true) == null) throw new SAXException( + "PARAMETER element missing TYPE attribute!"); this.iEmbObjHandler = EmbObjHandler.init(this.iEmbObjHandler, getNodeName(), pAttribs, this.iSession, this.iQualiHandler, true); } |
From: Dave B. <bla...@us...> - 2013-11-11 22:19:11
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv26816/src/org/sblim/cimclient/internal/cimxml Modified Files: Tag: Experimental CIMXMLParserImpl.java Log Message: 2704 PARAMETER does not require TYPE attribute Index: CIMXMLParserImpl.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/CIMXMLParserImpl.java,v retrieving revision 1.14.2.69 retrieving revision 1.14.2.70 diff -u -d -r1.14.2.69 -r1.14.2.70 --- CIMXMLParserImpl.java 8 Nov 2013 15:42:44 -0000 1.14.2.69 +++ CIMXMLParserImpl.java 11 Nov 2013 22:19:09 -0000 1.14.2.70 @@ -85,6 +85,7 @@ * 2701 2013-11-07 blaschke-oss PROPERTY.ARRAY does not require TYPE attribute * 2702 2013-11-07 blaschke-oss Bad PROPERTY.ARRAY ARRAYSIZE generates NumberFormatException * 2703 2013-11-08 blaschke-oss MethodNode should not require TYPE attribute + * 2704 2013-11-11 blaschke-oss PARAMETER does not require TYPE attribute */ package org.sblim.cimclient.internal.cimxml; @@ -1263,6 +1264,8 @@ String name = attribute(pParamE, "NAME"); if (name == null) throw new CIMXMLParseException( "PARAMETER element missing NAME attribute!"); + if (attribute(pParamE, "TYPE") == null) throw new CIMXMLParseException( + "PARAMETER element missing TYPE attribute!"); EmbObjHandler iEmbObjHandler = new EmbObjHandler(pParamE); // CIMParameter(String name, CIMDataType type, CIMQualifier[] // qualifiers) |
From: Dave B. <bla...@us...> - 2013-11-08 15:42:46
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv4919/src/org/sblim/cimclient/internal/cimxml/sax/node Modified Files: Tag: Experimental MethodNode.java Log Message: 2703 MethodNode should not require TYPE attribute Index: MethodNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/MethodNode.java,v retrieving revision 1.1.2.12 retrieving revision 1.1.2.13 diff -u -d -r1.1.2.12 -r1.1.2.13 --- MethodNode.java 30 Jan 2013 14:57:10 -0000 1.1.2.12 +++ MethodNode.java 8 Nov 2013 15:42:44 -0000 1.1.2.13 @@ -23,6 +23,7 @@ * 2763216 2009-04-14 blaschke-oss Code cleanup: visible spelling/grammar errors * 2797550 2009-06-01 raman_arora JSR48 compliance - add Java Generics * 3602604 2013-01-29 blaschke-oss Clean up SAXException messages + * 2703 2013-11-08 blaschke-oss MethodNode should not require TYPE attribute */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -88,7 +89,7 @@ this.iName = getCIMName(pAttribs); - this.iType = getCIMType(pAttribs, false); + this.iType = getCIMType(pAttribs, true); if (this.iType != null && this.iType.isArray()) throw new SAXException( "METHOD node's TYPE cannot be an array!"); this.iClassOrigin = getClassOrigin(pAttribs); @@ -124,7 +125,7 @@ @Override public void testCompletness() throws SAXException { this.iType = this.iEmbObjHandler.getType(); - if (this.iType.isArray()) throw new SAXException( + if (this.iType != null && this.iType.isArray()) throw new SAXException( "METHOD node's TYPE attribute cannot be an array!"); } |
From: Dave B. <bla...@us...> - 2013-11-07 22:40:18
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv2584/src/org/sblim/cimclient/internal/cimxml/sax/node Modified Files: Tag: Experimental Node.java Log Message: 2702 Bad PROPERTY.ARRAY ARRAYSIZE generates NumberFormatException Index: Node.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/Node.java,v retrieving revision 1.1.2.15 retrieving revision 1.1.2.16 diff -u -d -r1.1.2.15 -r1.1.2.16 --- Node.java 21 Oct 2013 11:25:26 -0000 1.1.2.15 +++ Node.java 7 Nov 2013 22:40:16 -0000 1.1.2.16 @@ -26,6 +26,7 @@ * 3602604 2013-01-29 blaschke-oss Clean up SAXException messages * 2605 2013-03-20 buccella SAX parser throws wrong exception * 2693 2013-10-21 blaschke-oss ReturnValueNode allows invalid PARAMTYPE attribute + * 2702 2013-11-07 blaschke-oss Bad PROPERTY.ARRAY ARRAYSIZE generates NumberFormatException */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -253,7 +254,13 @@ // Yes if ISARRAY is true or ARRAYSIZE>-1. boolean isArray = hasTrueAttribute(pAttribs, "ISARRAY"); String arraySizeStr = pAttribs.getValue("ARRAYSIZE"); - int arraySize = (arraySizeStr == null ? (isArray ? 0 : -1) : Integer.parseInt(arraySizeStr)); + int arraySize; + try { + arraySize = (arraySizeStr == null || arraySizeStr.length() == 0 ? (isArray ? 0 : -1) + : Integer.parseInt(arraySizeStr)); + } catch (NumberFormatException e) { + throw new SAXException(arraySizeStr + " is not a valid ARRAYSIZE attribute!"); + } if (isArray || arraySize >= 0) { if (arraySize > 0) return new CIMDataType(type.getType(), arraySize); return CIMHelper.UnboundedArrayDataType(type.getType()); |
From: Dave B. <bla...@us...> - 2013-11-07 21:10:07
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv29031/src/org/sblim/cimclient/internal/cimxml/sax/node Modified Files: Tag: Experimental PropertyArrayNode.java Log Message: 2701 PROPERTY.ARRAY does not require TYPE attribute Index: PropertyArrayNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/PropertyArrayNode.java,v retrieving revision 1.1.2.11 retrieving revision 1.1.2.12 diff -u -d -r1.1.2.11 -r1.1.2.12 --- PropertyArrayNode.java 1 Jun 2009 17:01:10 -0000 1.1.2.11 +++ PropertyArrayNode.java 7 Nov 2013 21:10:05 -0000 1.1.2.12 @@ -1,5 +1,5 @@ /** - * (C) Copyright IBM Corp. 2006, 2009 + * (C) Copyright IBM Corp. 2006, 2013 * * THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE * ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE @@ -21,6 +21,7 @@ * 2003590 2008-06-30 blaschke-oss Change licensing from CPL to EPL * 2524131 2009-01-21 raman_arora Upgrade client to JDK 1.5 (Phase 1) * 2797550 2009-06-01 raman_arora JSR48 compliance - add Java Generics + * 2701 2013-11-07 blaschke-oss PROPERTY.ARRAY does not require TYPE attribute */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -52,6 +53,8 @@ // required for super.testChild() private boolean iHasValueArray; + private boolean iHasTypeAttribute; + private CIMDataType iType; private Object iValue; @@ -67,13 +70,16 @@ @Override protected void specificInit(Attributes pAttribs, SAXSession pSession) throws SAXException { + this.iHasTypeAttribute = (getCIMType(pAttribs, true) != null); this.iEmbObjHandler = EmbObjHandler.init(this.iEmbObjHandler, getNodeName(), pAttribs, pSession, this.iQualiHandler, true); this.iHasValueArray = false; } @Override - protected void childValueNodeParsed(Node pChild) { + protected void childValueNodeParsed(Node pChild) throws SAXException { + if (!this.iHasTypeAttribute && ((ValueArrayNode) pChild).getType() == null) throw new SAXException( + "PROPERTY.ARRAY element missing TYPE attribute!"); this.iEmbObjHandler.addValueNode((ValueArrayNode) pChild); this.iHasValueArray = true; } |
From: Dave B. <bla...@us...> - 2013-11-07 19:08:39
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv20417/src/org/sblim/cimclient/internal/cimxml Modified Files: Tag: Experimental CIMXMLParserImpl.java Log Message: 2700 PROPERTY does not require TYPE attribute Index: CIMXMLParserImpl.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/CIMXMLParserImpl.java,v retrieving revision 1.14.2.65 retrieving revision 1.14.2.66 diff -u -d -r1.14.2.65 -r1.14.2.66 --- CIMXMLParserImpl.java 6 Nov 2013 02:35:25 -0000 1.14.2.65 +++ CIMXMLParserImpl.java 7 Nov 2013 19:08:37 -0000 1.14.2.66 @@ -81,6 +81,7 @@ * 2695 2013-10-25 blaschke-oss parseMETHODCALL allows LOCALCLASSPATH and LOCALINSTANCEPATH * 2696 2013-10-29 blaschke-oss parseIRETURNVALUE ignores VALUE and VALUE.ARRAY * 2699 2013-11-05 blaschke-oss parseQUALIFIER does not require TYPE attribute + * 2700 2013-11-07 blaschke-oss PROPERTY does not require TYPE attribute */ package org.sblim.cimclient.internal.cimxml; @@ -2022,6 +2023,8 @@ if (property_nameA == null) throw new CIMXMLParseException( "PROPERTY element missing NAME attribute!"); String name = property_nameA.getNodeValue(); + if (attribute(pPropertyE, "TYPE") == null && !hasTypeAttrsInNodes(pPropertyE)) throw new CIMXMLParseException( + "PROPERTY element missing TYPE attribute!"); String classOrigin = pPropertyE.getAttribute("CLASSORIGIN"); if (classOrigin != null && classOrigin.length() == 0) classOrigin = null; @@ -3159,7 +3162,9 @@ String name = n.getNodeName(); if ("VALUE".equalsIgnoreCase(name) || "VALUE.ARRAY".equalsIgnoreCase(name)) { NamedNodeMap nm = n.getAttributes(); - if (nm != null && nm.getNamedItem("TYPE") != null) return true; + if (nm != null + && (nm.getNamedItem("TYPE") != null || nm.getNamedItem("PARAMTYPE") != null)) return true; + } } return false; |
From: Dave B. <bla...@us...> - 2013-11-06 16:41:45
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv10439/src/org/sblim/cimclient/internal/cimxml/sax Modified Files: CIMObjectFactory.java Log Message: 2693 ReturnValueNode allows invalid PARAMTYPE attribute Index: CIMObjectFactory.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/CIMObjectFactory.java,v retrieving revision 1.19 retrieving revision 1.20 diff -u -d -r1.19 -r1.20 --- CIMObjectFactory.java 15 Nov 2012 14:46:05 -0000 1.19 +++ CIMObjectFactory.java 6 Nov 2013 16:41:43 -0000 1.20 @@ -1,5 +1,5 @@ /** - * (C) Copyright IBM Corp. 2006, 2012 + * (C) Copyright IBM Corp. 2006, 2013 * * THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE * ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE @@ -26,6 +26,7 @@ * 3027615 2010-07-12 blaschke-oss Use CLASS_ARRAY_T instead of new CIMDataType(CLASS,0) * 3513349 2012-03-31 blaschke-oss TCK: CIMDataType must not accept null string * 3572993 2012-10-01 blaschke-oss parseDouble("2.2250738585072012e-308") DoS vulnerability + * 2693 2013-10-21 blaschke-oss ReturnValueNode allows invalid PARAMTYPE attribute */ package org.sblim.cimclient.internal.cimxml.sax; @@ -270,11 +271,15 @@ * * @param pTypeStr * @return CIMDataType + * @throws SAXException */ - public static CIMDataType getType(String pTypeStr) { + public static CIMDataType getType(String pTypeStr) throws SAXException { if (pTypeStr == null) return null; createTypeStrMap(); - return cTypeStrMap.get(pTypeStr); + CIMDataType type = cTypeStrMap.get(pTypeStr); + if (type == null && !cTypeStrMap.containsKey(pTypeStr)) throw new SAXException(pTypeStr + + " is invalid PARAMTYPE!"); + return type; } static final CIMInstance[] EMPTY_INST_A = new CIMInstance[0]; |
From: Dave B. <bla...@us...> - 2013-11-06 16:34:49
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv10034/src/org/sblim/cimclient/internal/cimxml/sax Modified Files: EmbObjHandler.java Log Message: 2691 RETURNVALUE should not require PARAMTYPE attribute Index: EmbObjHandler.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/EmbObjHandler.java,v retrieving revision 1.14 retrieving revision 1.15 diff -u -d -r1.14 -r1.15 --- EmbObjHandler.java 16 Apr 2012 12:44:38 -0000 1.14 +++ EmbObjHandler.java 6 Nov 2013 16:34:47 -0000 1.15 @@ -1,5 +1,5 @@ /** - * (C) Copyright IBM Corp. 2006, 2012 + * (C) Copyright IBM Corp. 2006, 2013 * * THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE * ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE @@ -25,6 +25,7 @@ * 3281781 2011-04-11 blaschke-oss fail to parse Embedded Instance parameter * 3513353 2012-03-30 blaschke-oss TCK: CIMDataType arrays must have length >= 1 * 3513349 2012-03-31 blaschke-oss TCK: CIMDataType must not accept null string + * 2691 2013-10-18 blaschke-oss RETURNVALUE should not require PARAMTYPE attribute */ package org.sblim.cimclient.internal.cimxml.sax; @@ -321,8 +322,8 @@ private void setType() throws SAXException { if (this.iType != null || this.iRawType != null) return; this.iRawType = this.iAbsValNode.getType(); - if (this.iRawType == null) throw new SAXException("Contained element " - + this.iAbsValNode.getNodeName() + " has unknown type!"); + if (this.iRawType == null) this.iRawType = (this.iAbsValNode instanceof ArrayIf ? CIMDataType.STRING_ARRAY_T + : CIMDataType.STRING_T); } } |
From: Dave B. <bla...@us...> - 2013-11-06 16:24:22
|
Update of /cvsroot/sblim/jsr48-client In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv9336 Modified Files: NEWS Log Message: 2537 Add new data types for PARAMVALUE Index: NEWS =================================================================== RCS file: /cvsroot/sblim/jsr48-client/NEWS,v retrieving revision 1.395 retrieving revision 1.396 diff -u -d -r1.395 -r1.396 --- NEWS 29 Oct 2013 13:50:59 -0000 1.395 +++ NEWS 6 Nov 2013 16:24:20 -0000 1.396 @@ -1,5 +1,6 @@ Changes in HEAD ================ + 2537 Add new data types for PARAMVALUE 2690 Remove RESPONSEDESTINATION support 2689 createMETHODCALL should not add PARAMTYPE attribute 2688 parseMETHODCALL looks for CIMName attribute instead of NAME |
From: Dave B. <bla...@us...> - 2013-11-06 02:35:28
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv19871/src/org/sblim/cimclient/internal/cimxml Modified Files: Tag: Experimental CIMXMLParserImpl.java Log Message: 2699 parseQUALIFIER does not require TYPE attribute Index: CIMXMLParserImpl.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/CIMXMLParserImpl.java,v retrieving revision 1.14.2.64 retrieving revision 1.14.2.65 diff -u -d -r1.14.2.64 -r1.14.2.65 --- CIMXMLParserImpl.java 29 Oct 2013 18:46:27 -0000 1.14.2.64 +++ CIMXMLParserImpl.java 6 Nov 2013 02:35:25 -0000 1.14.2.65 @@ -80,6 +80,7 @@ * 2694 2013-10-25 blaschke-oss NAME attribute not required by DOM parser (part 2) * 2695 2013-10-25 blaschke-oss parseMETHODCALL allows LOCALCLASSPATH and LOCALINSTANCEPATH * 2696 2013-10-29 blaschke-oss parseIRETURNVALUE ignores VALUE and VALUE.ARRAY + * 2699 2013-11-05 blaschke-oss parseQUALIFIER does not require TYPE attribute */ package org.sblim.cimclient.internal.cimxml; @@ -1497,6 +1498,9 @@ String name = attribute(pQualifierE, "NAME"); if (name == null) throw new CIMXMLParseException( "QUALIFIER element missing NAME attribute!"); + String typeStr = attribute(pQualifierE, "TYPE"); + if (typeStr == null && !hasTypeAttrsInNodes(pQualifierE)) throw new CIMXMLParseException( + "QUALIFIER element missing TYPE attribute!"); boolean propagated = MOF.TRUE.equalsIgnoreCase(pQualifierE.getAttribute("PROPAGATED")); // FLAVORS int flavors = parseFLAVORS(pQualifierE); @@ -1530,7 +1534,7 @@ String name = attribute(pQualifierTypeE, "NAME"); if (name == null) throw new CIMXMLParseException( "QUALIFIER.DECLARATION element missing NAME attribute!"); - if (attribute(pQualifierTypeE, "TYPE") == null) throw new CIMXMLParseException( + if (attribute(pQualifierTypeE, "TYPE") == null && !hasTypeAttrsInNodes(pQualifierTypeE)) throw new CIMXMLParseException( "QUALIFIER.DECLARATION element missing TYPE attribute!"); // SCOPES @@ -3138,6 +3142,30 @@ } /** + * hasTypeAttrsInNodes + * + * SVC CIMOM sends typed CIM-XML elements in a non-standard way. The TYPE + * attribute is included in the VALUE or VALUE.ARRAY element not in the + * enclosing element as the standard says. + * + * @param pParentE + * @return boolean + */ + private static boolean hasTypeAttrsInNodes(Element pParentE) { + NodeList nl = pParentE.getChildNodes(); + if (nl == null || nl.getLength() == 0) return false; + for (int i = 0; i < nl.getLength(); i++) { + Node n = nl.item(i); + String name = n.getNodeName(); + if ("VALUE".equalsIgnoreCase(name) || "VALUE.ARRAY".equalsIgnoreCase(name)) { + NamedNodeMap nm = n.getAttributes(); + if (nm != null && nm.getNamedItem("TYPE") != null) return true; + } + } + return false; + } + + /** * searchNodes * * @param pParentE |
From: Dave B. <bla...@us...> - 2013-11-06 02:35:27
|
Update of /cvsroot/sblim/jsr48-client/utst/org/sblim/cimclient/unittest/wbem/data In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv19871/utst/org/sblim/cimclient/unittest/wbem/data Modified Files: Tag: Experimental SVCEnumQualiTypes.xml Log Message: 2699 parseQUALIFIER does not require TYPE attribute Index: SVCEnumQualiTypes.xml =================================================================== RCS file: /cvsroot/sblim/jsr48-client/utst/org/sblim/cimclient/unittest/wbem/data/SVCEnumQualiTypes.xml,v retrieving revision 1.1.2.2 retrieving revision 1.1.2.3 diff -u -d -r1.1.2.2 -r1.1.2.3 --- SVCEnumQualiTypes.xml 2 Oct 2013 17:26:21 -0000 1.1.2.2 +++ SVCEnumQualiTypes.xml 6 Nov 2013 02:35:25 -0000 1.1.2.3 @@ -4,10 +4,10 @@ <SIMPLERSP> <IMETHODRESPONSE NAME="EnumerateQualifiers"> <IRETURNVALUE> - <QUALIFIER.DECLARATION NAME="BoolQuali" TYPE="boolean"> + <QUALIFIER.DECLARATION NAME="BoolQuali"> <VALUE TYPE="boolean">FALSE</VALUE> </QUALIFIER.DECLARATION> - <QUALIFIER.DECLARATION NAME="IntAQuali" TYPE="sint32"> + <QUALIFIER.DECLARATION NAME="IntAQuali"> <VALUE.ARRAY TYPE="sint32"> <VALUE>-5</VALUE><VALUE>15</VALUE> </VALUE.ARRAY> |
From: Dave H. <hel...@us...> - 2013-11-04 18:20:31
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "sfcb - Small Footprint CIM Broker". The branch, master has been updated via bde75719684c814f23e374ec16459db2333b4e98 (commit) from 4b3fed45722f43c1ec901251205a3628eaa094b4 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit bde75719684c814f23e374ec16459db2333b4e98 Author: Dave Heller <hel...@us...> Date: Mon Nov 4 13:15:49 2013 -0500 [sfcb-tix:#88] Ensure unique semaphore keys across multiple http adapters ----------------------------------------------------------------------- Summary of changes: httpAdapter.c | 34 ++++++++++++++++++++++------------ sfcBroker.c | 6 +++--- 2 files changed, 25 insertions(+), 15 deletions(-) diff --git a/httpAdapter.c b/httpAdapter.c index b3ef7d8..f374c08 100644 --- a/httpAdapter.c +++ b/httpAdapter.c @@ -229,10 +229,15 @@ extern int fallback_ipv4; #define TERMINATE(x) { if (!doFork) _SFCB_RETURN(x); commClose(conn_fd); exit(x); } void -initHttpProcCtl(int p) +initHttpProcCtl(int p, int adapterNum) { - httpProcSemKey = ftok(SFCB_BINARY, 'H'); - httpWorkSemKey = ftok(SFCB_BINARY, 'W'); + /* + * ftok uses only the lowest 8 bits of proj_id, for 256 possible keys per + * pathname. We need two keys per pathname per process, so we can support + * up to 128 adapters before colliding. + * */ + httpProcSemKey = ftok(SFCB_BINARY, adapterNum + 0); + httpWorkSemKey = ftok(SFCB_BINARY, adapterNum + 127); union semun sun; int i; @@ -264,7 +269,7 @@ initHttpProcCtl(int p) semget(httpWorkSemKey, 1, IPC_CREAT | IPC_EXCL | 0600)) == -1) { char *emsg = strerror(errno); mlogf(M_ERROR, M_SHOW, - "\n--- Http ProcWork semaphore create key: 0x%x failed: %s\n", + "\n--- Http Work semaphore create key: 0x%x failed: %s\n", httpWorkSemKey, emsg); mlogf(M_ERROR, M_SHOW, " use \"ipcrm -S 0x%x\" to remove semaphore\n\n", @@ -1444,7 +1449,6 @@ handleHttpRequest(int connFd, int __attribute__ ((unused)) sslMode) CommHndl conn_fd; int isReady; fd_set httpfds; - // struct sembuf procReleaseUnDo = { 0, 1, SEM_UNDO }; struct timeval httpTimeout; int breakloop; @@ -1454,10 +1458,16 @@ handleHttpRequest(int connFd, int __attribute__ ((unused)) sslMode) _SFCB_TRACE(1, ("--- Forking request processor")); semAcquire(httpWorkSem, 0); semAcquire(httpProcSem, 0); - for (httpProcIdX = 0; httpProcIdX < hMax; httpProcIdX++) - if (semGetValue(httpProcSem, httpProcIdX + 1) == 0) + for (httpProcIdX = 1; httpProcIdX <= hMax; httpProcIdX++) + if (semGetValue(httpProcSem, httpProcIdX) == 0) break; - // procReleaseUnDo.sem_num = httpProcIdX + 1; + + /* This should not happen, but if it does exit the req handler gracefully */ + if (httpProcIdX > hMax) { + semRelease(httpProcSem, 0); + semRelease(httpWorkSem, 0); + return; + } sessionId++; r = fork(); @@ -1470,7 +1480,7 @@ handleHttpRequest(int connFd, int __attribute__ ((unused)) sslMode) processName = "CIMREQ-Processor"; semRelease(httpProcSem, 0); semAcquireUnDo(httpProcSem, 0); - semReleaseUnDo(httpProcSem, httpProcIdX + 1); + semReleaseUnDo(httpProcSem, httpProcIdX); semRelease(httpWorkSem, 0); atexit(releaseAuthHandle); atexit(uninitGarbageCollector); @@ -1482,7 +1492,7 @@ handleHttpRequest(int connFd, int __attribute__ ((unused)) sslMode) if (labelProcs) { append2Argv(" -reqhandler: "); char handlerId[8]; - sprintf(handlerId, "%d", httpProcIdX + 1); + sprintf(handlerId, "%d", httpProcIdX); append2Argv(handlerId); } } @@ -2135,7 +2145,7 @@ initSSL() #endif // USE_SSL int -httpDaemon(int argc, char *argv[], int sslMode, char *ipAddr, +httpDaemon(int argc, char *argv[], int sslMode, int adapterNum, char *ipAddr, sa_family_t ipAddrFam, int sfcbPid) { @@ -2215,7 +2225,7 @@ httpDaemon(int argc, char *argv[], int sslMode, char *ipAddr, doFork = 0; } - initHttpProcCtl(hMax); + initHttpProcCtl(hMax, adapterNum); if (getControlBool("doBasicAuth", &doBa)) doBa = 0; diff --git a/sfcBroker.c b/sfcBroker.c index 2e3e25c..0f4ed46 100644 --- a/sfcBroker.c +++ b/sfcBroker.c @@ -62,7 +62,7 @@ extern int init_sfcBroker(); extern CMPIBroker *Broker; extern void initProvProcCtl(int); extern void processTerminated(int pid); -extern int httpDaemon(int argc, char *argv[], int sslMode, char *ipAddr, sa_family_t ipAddrFam); +extern int httpDaemon(int argc, char *argv[], int sslMode, int adapterNum, char *ipAddr, sa_family_t ipAddrFam); extern void processProviderMgrRequests(); extern int stopNextProc(); @@ -532,10 +532,10 @@ startHttpd(int argc, char *argv[], int sslMode) exit(2); } } - if (httpDaemon(argc, argv, sslMode, (ipAddrList + i)->addrStr, + if (httpDaemon(argc, argv, sslMode, i+1, (ipAddrList + i)->addrStr, (ipAddrList + i)->addrFam)) { //kill(sfcPid, 3); /* if port in use, shutdown */ - /* (don't do this anymore - xxxxxxx) */ + /* (don't do this anymore - 3597806) */ } closeSocket(&sfcbSockets,cRcv,"startHttpd"); closeSocket(&resultSockets,cAll,"startHttpd"); hooks/post-receive -- sfcb - Small Footprint CIM Broker |
From: Dave H. <hel...@us...> - 2013-11-04 05:55:03
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "sfcb - Small Footprint CIM Broker". The branch, master has been updated via 4b3fed45722f43c1ec901251205a3628eaa094b4 (commit) from 2fd9b09d6dd874ee1dc222260753b9648acfe043 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 4b3fed45722f43c1ec901251205a3628eaa094b4 Author: Dave Heller <hel...@us...> Date: Mon Nov 4 00:54:03 2013 -0500 [sfcb-tix:#76] Label Req Handlers too ----------------------------------------------------------------------- Summary of changes: httpAdapter.c | 10 ++++++++++ sfcbproc.c | 15 ++++++++++++++- 2 files changed, 24 insertions(+), 1 deletions(-) diff --git a/httpAdapter.c b/httpAdapter.c index 1c6003c..b3ef7d8 100644 --- a/httpAdapter.c +++ b/httpAdapter.c @@ -1475,6 +1475,16 @@ handleHttpRequest(int connFd, int __attribute__ ((unused)) sslMode) atexit(releaseAuthHandle); atexit(uninitGarbageCollector); atexit(sunsetControl); + + /* Label the process by modifying the cmdline */ + extern void append2Argv(char *appendstr); + extern unsigned int labelProcs; + if (labelProcs) { + append2Argv(" -reqhandler: "); + char handlerId[8]; + sprintf(handlerId, "%d", httpProcIdX + 1); + append2Argv(handlerId); + } } /* * parent's thread of execution diff --git a/sfcbproc.c b/sfcbproc.c index a332462..dfcde72 100644 --- a/sfcbproc.c +++ b/sfcbproc.c @@ -336,8 +336,21 @@ static int getProcStat(int pid, ProcStat *p) { } int pass = 0; *p->cmd = '\0'; + /* + * Note getdelim() will normally return 0 if there is no data to be read + * other than a delim char. But when the delim char is NULL, getdelim() + * will always return at least one. Therefore, read=1 => no more data. + */ while ((read = getdelim(&line, &len, 0, fp)) != -1) { - if (strlen(p->cmd) + strlen(line) > MAX_CMD_SZ-2) { + if ((read <= 1) || strlen(p->cmd) + (read-1) > MAX_CMD_SZ-2) { + /* + * Breaking when no data has been read is akin to breaking on the first + * occurrence of a double-null. The intent is to clean up --raw output + * by discarding the trailing nulls in argv when labelProcs is in effect + * [sfcb-tix:#76]. If for some strange reason there is an occurrence of + * a double-null somewhere in argv and there is additional data beyond + * that, this would hide the additional data. + */ break; } else { hooks/post-receive -- sfcb - Small Footprint CIM Broker |
From: Dave H. <hel...@us...> - 2013-10-31 23:00:48
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "sfcb - Small Footprint CIM Broker". The branch, master has been updated via 2fd9b09d6dd874ee1dc222260753b9648acfe043 (commit) from cc5e641739542c764d9803119720641447d9ea32 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 2fd9b09d6dd874ee1dc222260753b9648acfe043 Author: Dave Heller <hel...@us...> Date: Thu Oct 31 19:00:18 2013 -0400 [sfcb-tix:#76] Identify running SFCB processes in ps output ----------------------------------------------------------------------- Summary of changes: contributions.txt | 1 + control.c | 51 ++++++++++++++++++++++++++++++++++++++++++ httpAdapter.c | 20 ++++++++++++++++ mlog.c | 7 ++++++ providerDrv.c | 13 +++++++++++ sfcBroker.c | 63 +++++++++++++++++++++++++++++++++++++++++++++++----- sfcb.cfg.pre.in | 11 ++++++++- sfcbproc.c | 2 +- 8 files changed, 160 insertions(+), 8 deletions(-) diff --git a/contributions.txt b/contributions.txt index bad54f6..1d55c32 100644 --- a/contributions.txt +++ b/contributions.txt @@ -125,6 +125,7 @@ Klaus Kampf, Novell 09/20/2013 [sfcb-tix:#75] fileRepository: show which directory could not be opened 09/30/2013 [sfcb-tix:#77] Fix prototype for stopBroker 10/01/2013 [sfcb-tix:#62] SIGSEGV in ClassProvider, return of 0 from addClParameter() not checked +10/31/2013 [sfcb-tix:#76] Identify running SFCB processes in ps output (contributions) Mike Brasher, Inova ------------------- diff --git a/control.c b/control.c index 1e64c42..0566dfd 100644 --- a/control.c +++ b/control.c @@ -71,9 +71,60 @@ char *configfile = NULL; char *ip4List= NULL; char *ip6List= NULL; +char **origArgv; +int origArgc; +unsigned int labelProcs; + +/** + * Kindly null terminate, always, even if might overwrite + * the last char of the truncated string. +*/ +inline char *strncpy_kind(char *to, char *from, size_t size) { + strncpy(to, from, size); + *(to + size - 1) = '\0'; + return to; +} + +/** + * Helper functions for labeling a process by modifying the process argv string. + * On the first call, convert the original argv[] to a contiguous string by + * replacing inter-arg nulls with spaces and adding a trailing space; then + * append appendstr. On subsequent calls only append appendstr. Passing + * NULL for appendstr forces the function to act as if called for the first + * time, i.e. reset the static ptr and prepare the argv[] string. + */ +void append2Argv(char *appendstr) { + int i; + static char *ptr = NULL; + if (!ptr || !appendstr) { /* called for the 1st time or intentionally reset */ + for (i=1 ; i < origArgc ; i++) + *(*(origArgv+i) - 1) = ' '; /* replace inter-arg nulls with spaces */ + ptr = origArgv[origArgc - 1]; + } + if (appendstr) + /* Enforce limit of appending no more than labelProcs chars */ + ptr += strlen(strncpy_kind(ptr, appendstr, + labelProcs - (ptr - origArgv[origArgc - 1]) + 1)); +} + +/** + * Restore the process argv[] to its original form by replacing inter-arg spaces + * with nulls. May be required prior to spawning a child process. To prepare for + * a full restart, additionally remove the pad argument. + */ +void restoreOrigArgv(int removePad) { + int i; + for (i=1 ; i < origArgc ; i++) + *(*(origArgv+i) - 1) = '\0'; /* restore inter-arg nulls */ + + if (removePad) + origArgv[origArgc - 1] = NULL; +} + /* Control initial values { property, type, string value, numeric value} */ static Control init[] = { + {"labelProcs", CTL_UINT, NULL, {.uint=0}}, {"ip4AddrList", CTL_STRING, NULL, {0}}, {"ip6AddrList", CTL_STRING, NULL, {0}}, {"httpPort", CTL_LONG, NULL, {.slong=5988}}, diff --git a/httpAdapter.c b/httpAdapter.c index 6ebf481..1c6003c 100644 --- a/httpAdapter.c +++ b/httpAdapter.c @@ -2282,6 +2282,26 @@ httpDaemon(int argc, char *argv[], int sslMode, char *ipAddr, keepaliveMaxRequest); } + /* Label the process by modifying the cmdline */ + extern void append2Argv(char *appendstr); + extern unsigned int labelProcs; + if (labelProcs) { + append2Argv(NULL); + append2Argv("-proc:HttpDaemon "); + append2Argv("-ip:"); + char *l = ""; + char *r = ""; +#ifdef HAVE_IPV6 + if (ipAddrFam == AF_INET6) { + l = "["; + r = "]"; + } +#endif + append2Argv(l); + append2Argv(ipAddr); + append2Argv(r); + } + if (enableHttp) { httpListenFd = getSocket(ipAddrFam); } diff --git a/mlog.c b/mlog.c index 177dfcc..176cc59 100644 --- a/mlog.c +++ b/mlog.c @@ -109,6 +109,13 @@ startLogging(int level, int thread) setSignal(SIGHUP, SIG_IGN, 0); setSignal(SIGUSR2, SIG_IGN, 0); + /* Label the process by modifying the cmdline */ + extern void append2Argv(char *appendstr); + extern unsigned int labelProcs; + if (labelProcs) { + append2Argv("-proc:Logger"); + } + runLogger(logfds[0], level); close(logfds[0]); diff --git a/providerDrv.c b/providerDrv.c index 2c3cb50..03f561b 100644 --- a/providerDrv.c +++ b/providerDrv.c @@ -896,6 +896,19 @@ getProcess(ProviderInfo * info, ProviderProcess ** proc) setSignal(SIGSEGV, handleSigSegv, SA_ONESHOT); + /* Label the process by modifying the cmdline */ + extern void append2Argv(char *appendstr); + extern unsigned int labelProcs; + if (labelProcs) { + append2Argv(NULL); + append2Argv("-proc:"); + append2Argv(info->providerName);; + append2Argv(" -class:"); + append2Argv(info->className); + append2Argv(" -location:"); + append2Argv(info->location); + } + // If requested, change the uid of the provider if (info->uid != -1) { _SFCB_TRACE(1, diff --git a/sfcBroker.c b/sfcBroker.c index c39eaa3..2e3e25c 100644 --- a/sfcBroker.c +++ b/sfcBroker.c @@ -104,6 +104,12 @@ extern char *configfile; extern char *ip4List; extern char *ip6List; +extern char **origArgv; +extern int origArgc; +extern unsigned int labelProcs; +extern void append2Argv(char *appendstr); +extern void restoreOrigArgv(int removePad); + #ifdef HAVE_IPV6 int fallback_ipv4 = 1; #endif @@ -338,6 +344,8 @@ handleSigHup(int sig) if (sfcBrokerPid == currentProc) { restartBroker = 1; + if (labelProcs) + restoreOrigArgv(1); fprintf(stderr, "--- Restarting %s\n", processName); pthread_attr_init(&tattr); pthread_attr_setdetachstate(&tattr, PTHREAD_CREATE_DETACHED); @@ -397,7 +405,17 @@ handleSigChld(int __attribute__ ((unused)) sig) static int reStartHttpd(void) { - return startHttpd(restartArgc, restartArgv, sslMode); + /* Restore orig argv or startup banner will be hosed on httpd restart */ + if (labelProcs) + restoreOrigArgv(0); + + int rc = startHttpd(restartArgc, restartArgv, sslMode); + + /* Relabel the process */ + if (labelProcs) + append2Argv(NULL); + + return rc; } static void @@ -637,8 +655,6 @@ main(int argc, char *argv[]) char *pauseStr; int daemonize=0; - sfcbUseSyslog=1; - name = strrchr(argv[0], '/'); if (name != NULL) ++name; @@ -651,8 +667,8 @@ main(int argc, char *argv[]) provPauseStr = getenv("SFCB_PAUSE_PROVIDER"); httpPauseStr = getenv("SFCB_PAUSE_CODEC"); currentProc = sfcBrokerPid = getpid(); - restartArgc = argc; - restartArgv = argv; + restartArgc = origArgc = argc; + restartArgv = origArgv = argv; exFlags = 0; @@ -748,7 +764,7 @@ main(int argc, char *argv[]) } } - if (optind < argc) { + if (optind < argc && *argv[optind] != 'X') { /* Ignore the pad argument */ fprintf(stderr, "SFCB not started: unrecognized config property %s\n", argv[optind]); usage(1); @@ -766,6 +782,36 @@ main(int argc, char *argv[]) currentProc=sfcBrokerPid=getpid(); /* req. on some systems */ } + setupControl(configfile); /* enable reading the config file */ + if ((getControlUNum("labelProcs", &labelProcs) == 0) && (labelProcs > 0)) { + if (*argv[argc-1] != 'X') { + /* Create an expanded argv */ + char **newArgv = malloc(sizeof(char*) * (argc + 2)); + memcpy(newArgv, argv, sizeof(char*) * argc); + + /* Create a pad argument of appropriate length */ + char *padArg = malloc(labelProcs + 1); + for (i=0; i < labelProcs; i++) + padArg[i] = 'X'; + padArg[i] = '\0'; + + /* Add pad argument and null terminator */ + newArgv[argc] = padArg; + newArgv[argc + 1] = NULL; + + /* Restart with expanded argv */ + fprintf(stderr, + "--- %s V" sfcHttpDaemonVersion " performing labelProcs allocation - %d\n", + name, currentProc); + execvp(newArgv[0], newArgv); + fprintf(stderr, "--- failed to execv for labelProcs allocation: %s\n", + strerror(errno)); + exit(1); + } + } + sunsetControl(); /* ensures setupControl() is re-run after startLogging() */ + + sfcbUseSyslog=1; startLogging(syslogLevel,1); mlogf(M_NOTICE, M_SHOW, "--- %s V" sfcHttpDaemonVersion " started - %d\n", @@ -1006,6 +1052,11 @@ mlogf(M_INFO, M_SHOW, "--- Request handlers enabled:%s\n",rtmsg); setSignal(SIGCHLD, handleSigChld, 0); setSignal(SIGUSR2, handleSigUsr2, 0); + /* Label the process by modifying the cmdline */ + if (labelProcs) { + append2Argv("-proc:Main"); + } + processProviderMgrRequests(); stopBroker(NULL); diff --git a/sfcb.cfg.pre.in b/sfcb.cfg.pre.in index d575a7e..41dbfb5 100644 --- a/sfcb.cfg.pre.in +++ b/sfcb.cfg.pre.in @@ -313,7 +313,7 @@ sslCiphers: ALL:!ADH:!LOW:!EXP:!MD5:@STRENGTH #slpRefreshInterval: 600 -##------------------------------------ Trace ---------------------------------- +##------------------------------- Trace and Debug ----------------------------- ## Location of the trace file. ## Can be overriden by setting environment variable SFCB_TRACE_FILE @@ -331,6 +331,15 @@ sslCiphers: ALL:!ADH:!LOW:!EXP:!MD5:@STRENGTH ## Default is 0. If trace mask is set (by any method) the default is 1. #traceLevel: 0 +## Label each process by adding identifying information to the process cmdline +## so that it appears in 'ps' output. The identifying info will be appended to +## the original argv data, following any passed arguments. The number of bytes +## appended is limited by the value of labelProcs. A value of about 100 should +## be enough in most cases. A smaller value may truncate the data, but this may +## be desired. A value of 0 means the feature is disabled. +## Default is 0 +#labelProcs: 100 + ##---------------------------- Indications ---------------------------- ## Indication provider calls to CBDeliverIndication() cause a thread to spawn diff --git a/sfcbproc.c b/sfcbproc.c index 6f25659..a332462 100644 --- a/sfcbproc.c +++ b/sfcbproc.c @@ -23,7 +23,7 @@ #define ERROR -1 #define BUFFER_SZ 32 -#define MAX_CMD_SZ 64 +#define MAX_CMD_SZ 256 #define MAX_PATH_SZ 64 #define MAX_PATTERN_SZ 32 #define MAX_PORTS 6 hooks/post-receive -- sfcb - Small Footprint CIM Broker |
From: Dave B. <bla...@us...> - 2013-10-30 02:05:52
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv1689/src/org/sblim/cimclient/internal/cimxml/sax/node Modified Files: Tag: Experimental MethodResponseNode.java IMethodResponseNode.java Log Message: 2697 (I)MethodResponseNode allows ERROR with PARAMVALUE Index: IMethodResponseNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/IMethodResponseNode.java,v retrieving revision 1.1.2.10 retrieving revision 1.1.2.11 diff -u -d -r1.1.2.10 -r1.1.2.11 --- IMethodResponseNode.java 27 Mar 2012 19:06:32 -0000 1.1.2.10 +++ IMethodResponseNode.java 30 Oct 2013 02:05:49 -0000 1.1.2.11 @@ -1,5 +1,5 @@ /** - * (C) Copyright IBM Corp. 2006, 2012 + * (C) Copyright IBM Corp. 2006, 2013 * * THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE * ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE @@ -21,6 +21,7 @@ * 2763216 2009-04-14 blaschke-oss Code cleanup: visible spelling/grammar errors * 2845211 2009-08-27 raman_arora Pull Enumeration Feature (SAX Parser) * 3511454 2012-03-27 blaschke-oss SAX nodes not reinitialized properly + * 2697 2012-10-29 blaschke-oss (I)MethodResponseNode allows ERROR with PARAMVALUE */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -57,6 +58,10 @@ private static final CIMArgument<?>[] EMPTY_ARG_A = new CIMArgument[0]; + private boolean iHasError; + + private boolean iHasRetVal; + /** * Ctor. */ @@ -81,6 +86,8 @@ this.iErrorNode = null; this.iRetValNode = null; if (this.iCIMArgAL != null) this.iCIMArgAL.clear(); + this.iHasError = false; + this.iHasRetVal = false; } /** @@ -93,16 +100,29 @@ @Override public void testChild(String pNodeNameEnum) throws SAXException { - if (pNodeNameEnum == ERROR || pNodeNameEnum == IRETURNVALUE) { + if (pNodeNameEnum == ERROR) { String ownedNodeName; - if (this.iRetValNode != null) ownedNodeName = IRETURNVALUE; - else if (this.iErrorNode != null) ownedNodeName = ERROR; + if (this.iHasRetVal) ownedNodeName = IRETURNVALUE; + else if (this.iHasError) ownedNodeName = ERROR; + else if (this.iCIMArgAL != null && this.iCIMArgAL.size() > 0) ownedNodeName = PARAMVALUE; else ownedNodeName = null; if (ownedNodeName != null) throw new SAXException(pNodeNameEnum + " child node is invalid for " + getNodeName() + " node, since it already has a " + ownedNodeName + " child node!"); - } else if (pNodeNameEnum != PARAMVALUE) throw new SAXException(getNodeName() - + " node cannot have " + pNodeNameEnum + " child node!"); + } else if (pNodeNameEnum == IRETURNVALUE) { + String ownedNodeName; + if (this.iHasRetVal) ownedNodeName = IRETURNVALUE; + else if (this.iHasError) ownedNodeName = ERROR; + else ownedNodeName = null; + if (ownedNodeName != null) throw new SAXException(pNodeNameEnum + + " child node is invalid for " + getNodeName() + + " node, since it already has a " + ownedNodeName + " child node!"); + } else if (pNodeNameEnum == PARAMVALUE) { + if (this.iHasError) throw new SAXException(pNodeNameEnum + + " child node is invalid for " + getNodeName() + + " node, since it already has an ERROR child node!"); + } else throw new SAXException(getNodeName() + " node cannot have " + pNodeNameEnum + + " child node!"); } /** @@ -110,6 +130,13 @@ */ @Override public void childParsed(Node pChild) { + if (pChild instanceof ErrorNode) { + this.iHasError = true; + this.iErrorNode = (ErrorNode) pChild; + } else if (pChild instanceof IReturnValueNode) { + this.iHasRetVal = true; + this.iRetValNode = (IReturnValueNode) pChild; + } else // Values of parameters should be stored in array if (pChild instanceof ParamValueNode) { if (this.iCIMArgAL == null) this.iCIMArgAL = new ArrayList<CIMArgument<Object>>(); Index: MethodResponseNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/MethodResponseNode.java,v retrieving revision 1.1.2.12 retrieving revision 1.1.2.13 diff -u -d -r1.1.2.12 -r1.1.2.13 --- MethodResponseNode.java 27 Mar 2012 19:06:32 -0000 1.1.2.12 +++ MethodResponseNode.java 30 Oct 2013 02:05:49 -0000 1.1.2.13 @@ -1,5 +1,5 @@ /** - * (C) Copyright IBM Corp. 2006, 2012 + * (C) Copyright IBM Corp. 2006, 2013 * * THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE * ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE @@ -23,6 +23,7 @@ * 2797550 2009-06-01 raman_arora JSR48 compliance - add Java Generics * 2845211 2009-08-27 raman_arora Pull Enumeration Feature (SAX Parser) * 3511454 2012-03-27 blaschke-oss SAX nodes not reinitialized properly + * 2697 2012-10-29 blaschke-oss (I)MethodResponseNode allows ERROR with PARAMVALUE */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -53,6 +54,10 @@ private ArrayList<CIMArgument<Object>> iCIMArgAL; + private boolean iHasError; + + private boolean iHasRetVal; + /** * Ctor. */ @@ -76,6 +81,8 @@ this.iError = null; this.iRetVal = null; if (this.iCIMArgAL != null) this.iCIMArgAL.clear(); + this.iHasError = false; + this.iHasRetVal = false; } /** @@ -88,23 +95,38 @@ @Override public void testChild(String pNodeNameEnum) throws SAXException { - if (pNodeNameEnum == ERROR || pNodeNameEnum == RETURNVALUE) { + if (pNodeNameEnum == ERROR) { String ownedNodeName; - if (this.iRetVal != null) ownedNodeName = RETURNVALUE; - else if (this.iError != null) ownedNodeName = ERROR; + if (this.iHasRetVal) ownedNodeName = RETURNVALUE; + else if (this.iHasError) ownedNodeName = ERROR; + else if (this.iCIMArgAL != null && this.iCIMArgAL.size() > 0) ownedNodeName = PARAMVALUE; else ownedNodeName = null; if (ownedNodeName != null) throw new SAXException(pNodeNameEnum + " child node is invalid for " + getNodeName() + " node, since it already has a " + ownedNodeName + " child node!"); - } else if (pNodeNameEnum != PARAMVALUE) throw new SAXException(getNodeName() - + " node cannot have " + pNodeNameEnum + " child node!"); + } else if (pNodeNameEnum == RETURNVALUE) { + String ownedNodeName; + if (this.iHasRetVal) ownedNodeName = RETURNVALUE; + else if (this.iHasError) ownedNodeName = ERROR; + else ownedNodeName = null; + if (ownedNodeName != null) throw new SAXException(pNodeNameEnum + + " child node is invalid for " + getNodeName() + + " node, since it already has a " + ownedNodeName + " child node!"); + } else if (pNodeNameEnum == PARAMVALUE) { + if (this.iHasError) throw new SAXException(pNodeNameEnum + + " child node is invalid for " + getNodeName() + + " node, since it already has an ERROR child node!"); + } else throw new SAXException(getNodeName() + " node cannot have " + pNodeNameEnum + + " child node!"); } @Override public void childParsed(Node pChild) { if (pChild instanceof ErrorNode) { + this.iHasError = true; this.iError = ((ErrorNode) pChild).getCIMError(); } else if (pChild instanceof ReturnValueNode) { + this.iHasRetVal = true; this.iRetVal = ((ReturnValueNode) pChild).getValue(); } else if (pChild instanceof ParamValueNode) { if (this.iCIMArgAL == null) this.iCIMArgAL = new ArrayList<CIMArgument<Object>>(); |
From: Dave B. <bla...@us...> - 2013-10-29 18:46:29
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv5358/src/org/sblim/cimclient/internal/cimxml Modified Files: Tag: Experimental CIMXMLParserImpl.java Log Message: 2696 parseIRETURNVALUE ignores VALUE and VALUE.ARRAY Index: CIMXMLParserImpl.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/CIMXMLParserImpl.java,v retrieving revision 1.14.2.63 retrieving revision 1.14.2.64 diff -u -d -r1.14.2.63 -r1.14.2.64 --- CIMXMLParserImpl.java 25 Oct 2013 15:55:20 -0000 1.14.2.63 +++ CIMXMLParserImpl.java 29 Oct 2013 18:46:27 -0000 1.14.2.64 @@ -79,6 +79,7 @@ * 2691 2013-10-18 blaschke-oss RETURNVALUE should not require PARAMTYPE attribute * 2694 2013-10-25 blaschke-oss NAME attribute not required by DOM parser (part 2) * 2695 2013-10-25 blaschke-oss parseMETHODCALL allows LOCALCLASSPATH and LOCALINSTANCEPATH + * 2696 2013-10-29 blaschke-oss parseIRETURNVALUE ignores VALUE and VALUE.ARRAY */ package org.sblim.cimclient.internal.cimxml; @@ -2969,23 +2970,24 @@ } // VALUE - // Vector valueV = searchNodes(ireturnvalueE, "VALUE"); - // if (valueV != null) { - // for (int i=0; i<valueV.size(); i++) { - // Element valueE = (Element)valueV.elementAt(i); - // String valueStr = parseVALUE(valueE); - // // cannot construct a CIMValue without type information - // } - // } + Element[] valElementA = searchNodes(pIRetValE, "VALUE"); + if (valElementA != null && valElementA.length > 0) { + for (int i = 0; i < valElementA.length; i++) { + Element valueE = valElementA[i]; + TypedValue tv = parseVALUE(valueE); + rtnV.add(tv.getValue()); + } + } // VALUE.ARRAY - // Vector valuearrayV = searchNodes(ireturnvalueE, "VALUE.ARRAY"); - // if (valuearrayV != null) { - // for (int i=0; i<valuearrayV.size(); i++) { - // Element valuearrayE = (Element)valuearrayV.elementAt(i); - // // cannot construct a CIMValue without type information - // } - // } + Element[] valArrayElementA = searchNodes(pIRetValE, "VALUE.ARRAY"); + if (valArrayElementA != null && valArrayElementA.length > 0) { + for (int i = 0; i < valArrayElementA.length; i++) { + Element valueArrayE = valArrayElementA[i]; + TypedValue tv = parseVALUEARRAY(valueArrayE); + rtnV.add(tv.getValue()); + } + } // VALUE.REFERENCE Element[] valRefElementA = searchNodes(pIRetValE, "VALUE.REFERENCE"); |
From: Dave B. <bla...@us...> - 2013-10-29 18:46:28
|
Update of /cvsroot/sblim/jsr48-client/utst/org/sblim/cimclient/unittest/wbem In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv5358/utst/org/sblim/cimclient/unittest/wbem Added Files: Tag: Experimental IReturnValueTest.java Log Message: 2696 parseIRETURNVALUE ignores VALUE and VALUE.ARRAY --- NEW FILE: IReturnValueTest.java --- /** * (C) Copyright IBM Corp. 2013 * * THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE * ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE * CONSTITUTES RECIPIENTS ACCEPTANCE OF THE AGREEMENT. * * You can obtain a current copy of the Eclipse Public License from * http://www.opensource.org/licenses/eclipse-1.0.php * * @author : Endre Bak, eb...@de... * Dave Blaschke, bla...@us... * * Flag Date Prog Description * ------------------------------------------------------------------------------- * 2696 2013-10-29 blaschke-oss parseIRETURNVALUE ignores VALUE and VALUE.ARRAY */ package org.sblim.cimclient.unittest.wbem; import java.io.ByteArrayInputStream; import java.io.InputStream; import javax.cim.CIMObjectPath; import javax.wbem.CloseableIterator; import org.sblim.cimclient.unittest.TestCase; /** * Tests the handling of VALUETYPE attribute of KEYVALUE XML element. */ public class IReturnValueTest extends TestCase { private static final String TEST_STR = "DEB"; private static final String VALUE_STR = "<?xml version=\"1.0\" encoding=\"utf-8\"?>" + "<CIM CIMVERSION=\"2.0\" DTDVERSION=\"2.0\">" + "<MESSAGE ID=\"7\" PROTOCOLVERSION=\"1.0\">" + "<SIMPLERSP>" + "<IMETHODRESPONSE NAME=\"EnumerateInstanceNames\">" + "<IRETURNVALUE>" + "<VALUE>" + TEST_STR + "</VALUE>" + "</IRETURNVALUE>" + "</IMETHODRESPONSE>" + "</SIMPLERSP>" + "</MESSAGE>" + "</CIM>"; private static final String VALUEARRAY_STR = "<?xml version=\"1.0\" encoding=\"utf-8\"?>" + "<CIM CIMVERSION=\"2.0\" DTDVERSION=\"2.0\">" + "<MESSAGE ID=\"7\" PROTOCOLVERSION=\"1.0\">" + "<SIMPLERSP>" + "<IMETHODRESPONSE NAME=\"EnumerateInstanceNames\">" + "<IRETURNVALUE>" + "<VALUE.ARRAY>" + "<VALUE>" + TEST_STR + "</VALUE>" + "</VALUE.ARRAY>" + "</IRETURNVALUE>" + "</IMETHODRESPONSE>" + "</SIMPLERSP>" + "</MESSAGE>" + "</CIM>"; private static final String VALUEREFERENCE_STR = "<?xml version=\"1.0\" encoding=\"utf-8\"?>" + "<CIM CIMVERSION=\"2.0\" DTDVERSION=\"2.0\">" + "<MESSAGE ID=\"7\" PROTOCOLVERSION=\"1.0\">" + "<SIMPLERSP>" + "<IMETHODRESPONSE NAME=\"EnumerateInstanceNames\">" + "<IRETURNVALUE>" + "<VALUE.REFERENCE>" + "<CLASSNAME NAME=\"" + TEST_STR + "\"/>" + "</VALUE.REFERENCE>" + "</IRETURNVALUE>" + "</IMETHODRESPONSE>" + "</SIMPLERSP>" + "</MESSAGE>" + "</CIM>"; private InputStream getIS(String pXML) { return new ByteArrayInputStream(pXML.getBytes()); } private void testValue(CloseableIterator<Object> pItr) { verify("Empty Iterator!", pItr.hasNext()); Object o = pItr.next(); verify("Return value not String!", o instanceof String); String s = (String) o; verify("Unexpected return value! " + TEST_STR + "!=" + s, TEST_STR.equalsIgnoreCase(s)); } private void testValueArray(CloseableIterator<Object> pItr) { verify("Empty Iterator!", pItr.hasNext()); Object o = pItr.next(); verify("Return value not String[]!", o instanceof String[]); String s[] = (String[]) o; verify("Unexpected return value! " + TEST_STR + "!=" + s[0], TEST_STR .equalsIgnoreCase(s[0])); } private void testValueReference(CloseableIterator<Object> pItr) { verify("Empty Iterator!", pItr.hasNext()); Object o = pItr.next(); verify("Return value not String!", o instanceof CIMObjectPath); CIMObjectPath cop = (CIMObjectPath) o; verify("Unexpected return value! " + TEST_STR + "!=" + cop.getObjectName(), TEST_STR .equalsIgnoreCase(cop.getObjectName())); } /** * testSAX * * @throws Exception */ public void testSAX() throws Exception { testValue(Common.parseWithSAX(getIS(VALUE_STR))); testValueArray(Common.parseWithSAX(getIS(VALUEARRAY_STR))); testValueReference(Common.parseWithSAX(getIS(VALUEREFERENCE_STR))); } /** * testPULL * * @throws Exception */ public void testPULL() throws Exception { testValue(Common.parseWithPULL(getIS(VALUE_STR))); testValueArray(Common.parseWithPULL(getIS(VALUEARRAY_STR))); testValueReference(Common.parseWithPULL(getIS(VALUEREFERENCE_STR))); } /** * testDOM * * @throws Exception */ public void testDOM() throws Exception { testValue(Common.parseWithDOM(getIS(VALUE_STR))); testValueArray(Common.parseWithDOM(getIS(VALUEARRAY_STR))); testValueReference(Common.parseWithDOM(getIS(VALUEREFERENCE_STR))); } } |
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv16628/src/org/sblim/cimclient/internal/cimxml/sax/node Modified Files: IMethodCallNode.java MethodCallNode.java AbstractMethodCallNode.java Removed Files: ResponseDestinationNode.java Log Message: 2690 Remove RESPONSEDESTINATION support Index: MethodCallNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/MethodCallNode.java,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- MethodCallNode.java 29 Oct 2013 12:11:59 -0000 1.7 +++ MethodCallNode.java 29 Oct 2013 13:50:58 -0000 1.8 @@ -19,6 +19,7 @@ * 2003590 2008-06-30 blaschke-oss Change licensing from CPL to EPL * 2524131 2009-01-21 raman_arora Upgrade client to JDK 1.5 (Phase 1) * 2682 2013-10-02 blaschke-oss (I)MethodCallNode allows no LOCAL*PATH + * 2690 2013-10-11 blaschke-oss Remove RESPONSEDESTINATION support */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -26,8 +27,8 @@ import org.xml.sax.SAXException; /** - * ELEMENT METHODCALL ((LOCALINSTANCEPATH | LOCALCLASSPATH), PARAMVALUE*, - * RESPONSEDESTINATION?) ATTLIST METHODCALL %CIMName; + * ELEMENT METHODCALL ((LOCALINSTANCEPATH | LOCALCLASSPATH), PARAMVALUE*) + * ATTLIST METHODCALL %CIMName; */ public class MethodCallNode extends AbstractMethodCallNode { Index: IMethodCallNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/IMethodCallNode.java,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- IMethodCallNode.java 29 Oct 2013 12:11:59 -0000 1.8 +++ IMethodCallNode.java 29 Oct 2013 13:50:58 -0000 1.9 @@ -19,6 +19,7 @@ * 2003590 2008-06-30 blaschke-oss Change licensing from CPL to EPL * 2524131 2009-01-21 raman_arora Upgrade client to JDK 1.5 (Phase 1) * 2682 2013-10-02 blaschke-oss (I)MethodCallNode allows no LOCAL*PATH + * 2690 2013-10-11 blaschke-oss Remove RESPONSEDESTINATION support */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -26,8 +27,8 @@ import org.xml.sax.SAXException; /** - * ELEMENT IMETHODCALL (LOCALNAMESPACEPATH, IPARAMVALUE*, RESPONSEDESTINATION?) - * ATTLIST IMETHODCALL %CIMName; + * ELEMENT IMETHODCALL (LOCALNAMESPACEPATH, IPARAMVALUE*) ATTLIST IMETHODCALL + * %CIMName; */ public class IMethodCallNode extends AbstractMethodCallNode { Index: AbstractMethodCallNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/AbstractMethodCallNode.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- AbstractMethodCallNode.java 29 Oct 2013 12:11:59 -0000 1.11 +++ AbstractMethodCallNode.java 29 Oct 2013 13:50:58 -0000 1.12 @@ -22,6 +22,7 @@ * 2797550 2009-06-01 raman_arora JSR48 compliance - add Java Generics * 3511454 2012-03-27 blaschke-oss SAX nodes not reinitialized properly * 2682 2013-10-02 blaschke-oss (I)MethodCallNode allows no LOCAL*PATH + * 2690 2013-10-11 blaschke-oss Remove RESPONSEDESTINATION support */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -38,11 +39,11 @@ /** * <pre> - * ELEMENT IMETHODCALL (LOCALNAMESPACEPATH, IPARAMVALUE*, RESPONSEDESTINATION?) + * ELEMENT IMETHODCALL (LOCALNAMESPACEPATH, IPARAMVALUE*) * ATTLIST IMETHODCALL * %CIMName; * - * ELEMENT METHODCALL ((LOCALINSTANCEPATH | LOCALCLASSPATH), PARAMVALUE*, RESPONSEDESTINATION?) + * ELEMENT METHODCALL ((LOCALINSTANCEPATH | LOCALCLASSPATH), PARAMVALUE*) * ATTLIST METHODCALL * %CIMName; * </pre> @@ -53,8 +54,6 @@ protected CIMObjectPath iPath; - private ResponseDestinationNode iRespDstNode; - /** * (IPARAMVALUE | PARAMVALUE)* -> ArrayList of CIMArgument */ @@ -81,7 +80,6 @@ public void init(Attributes pAttribs, SAXSession pSession) throws SAXException { this.iName = getCIMName(pAttribs); this.iPath = null; - this.iRespDstNode = null; this.iArgAL = null; this.iArgA = null; } @@ -100,8 +98,6 @@ } else if (pChild instanceof AbstractParamValueNode) { if (this.iArgAL == null) this.iArgAL = new ArrayList<CIMArgument<?>>(); this.iArgAL.add(((AbstractParamValueNode) pChild).getCIMArgument()); - } else { - this.iRespDstNode = (ResponseDestinationNode) pChild; } } @@ -117,12 +113,7 @@ @Override public void testChild(String pNodeNameEnum) throws SAXException { - if (pNodeNameEnum == RESPONSEDESTINATION) { - if (this.iRespDstNode != null) throw new SAXException(getNodeName() - + " node can have only one " + RESPONSEDESTINATION + " child node!"); - } else { - testSpecChild(pNodeNameEnum); - } + testSpecChild(pNodeNameEnum); } /** --- ResponseDestinationNode.java DELETED --- |
From: Dave B. <bla...@us...> - 2013-10-29 13:33:19
|
Update of /cvsroot/sblim/jsr48-client In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv15521 Modified Files: NEWS Log Message: 2689 createMETHODCALL should not add PARAMTYPE attribute Index: NEWS =================================================================== RCS file: /cvsroot/sblim/jsr48-client/NEWS,v retrieving revision 1.393 retrieving revision 1.394 diff -u -d -r1.393 -r1.394 --- NEWS 29 Oct 2013 13:04:04 -0000 1.393 +++ NEWS 29 Oct 2013 13:33:16 -0000 1.394 @@ -1,5 +1,6 @@ Changes in HEAD ================ + 2689 createMETHODCALL should not add PARAMTYPE attribute 2688 parseMETHODCALL looks for CIMName attribute instead of NAME 2687 ExpParamValueNode allows VALUE, (I)METHODRESPONSE children 2686 parseEXPPARAMVALUE allows 2+ children, prohibits 0 |
From: Dave B. <bla...@us...> - 2013-10-29 13:04:06
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv13609/src/org/sblim/cimclient/internal/cimxml Modified Files: CIMXMLParserImpl.java Log Message: 2688 parseMETHODCALL looks for CIMName attribute instead of NAME Index: CIMXMLParserImpl.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/CIMXMLParserImpl.java,v retrieving revision 1.67 retrieving revision 1.68 diff -u -d -r1.67 -r1.68 --- CIMXMLParserImpl.java 29 Oct 2013 12:50:00 -0000 1.67 +++ CIMXMLParserImpl.java 29 Oct 2013 13:04:04 -0000 1.68 @@ -74,6 +74,7 @@ * 2684 2013-10-07 blaschke-oss parseEXPMETHODRESPONSE has several issues * 2685 2013-10-07 blaschke-oss Element.getAttribute returns empty string if no attribute * 2686 2013-10-10 blaschke-oss parseEXPPARAMVALUE allows 2+ children, prohibits 0 + * 2688 2013-10-10 blaschke-oss parseMETHODCALL looks for CIMName attribute instead of NAME */ package org.sblim.cimclient.internal.cimxml; @@ -2450,11 +2451,11 @@ // ((LOCALCLASSPATH|LOCALINSTANCEPATH),PARAMVALUE*)> // <!ATTLIST METHODCALL // %CIMName;> - if (attribute(pMethodCallE, "NAME") == null) throw new CIMXMLParseException( - "METHODCALL element missing NAME attribute!"); CIMRequest request = new CIMRequest(); - String methodname = pMethodCallE.getAttribute("CIMName"); + String methodname = attribute(pMethodCallE, "NAME"); + if (methodname == null) throw new CIMXMLParseException( + "METHODCALL element missing NAME attribute!"); request.setMethodName(methodname); // EXPMETHODCALL |
From: Dave B. <bla...@us...> - 2013-10-29 12:57:09
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv13048/src/org/sblim/cimclient/internal/cimxml/sax/node Modified Files: ExpParamValueNode.java Log Message: 2687 ExpParamValueNode allows VALUE, (I)METHODRESPONSE children Index: ExpParamValueNode.java =================================================================== RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/sax/node/ExpParamValueNode.java,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- ExpParamValueNode.java 13 Apr 2012 12:59:51 -0000 1.7 +++ ExpParamValueNode.java 29 Oct 2013 12:57:06 -0000 1.8 @@ -1,5 +1,5 @@ /** - * (C) Copyright IBM Corp. 2006, 2012 + * (C) Copyright IBM Corp. 2006, 2013 * * THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE * ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE @@ -19,6 +19,7 @@ * 2003590 2008-06-30 blaschke-oss Change licensing from CPL to EPL * 2524131 2009-01-21 raman_arora Upgrade client to JDK 1.5 (Phase 1) * 3511454 2012-03-27 blaschke-oss SAX nodes not reinitialized properly + * 2687 2013-10-10 blaschke-oss ExpParamValueNode allows VALUE, (I)METHODRESPONSE children */ package org.sblim.cimclient.internal.cimxml.sax.node; @@ -29,7 +30,7 @@ /** * <pre> - * ELEMENT EXPPARAMVALUE (INSTANCE?|VALUE?|METHODRESPONSE?|IMETHODRESPONSE?) + * ELEMENT EXPPARAMVALUE (INSTANCE?) * ATTLIST EXPPARAMVALUE * %CIMName; * </pre> @@ -72,9 +73,8 @@ public void testChild(String pNodeNameEnum) throws SAXException { if (this.iChildNode != null) throw new SAXException(getNodeName() + " node can have only one child node!"); - if (pNodeNameEnum != INSTANCE && pNodeNameEnum != VALUE && pNodeNameEnum != METHODRESPONSE - && pNodeNameEnum != IMETHODRESPONSE) throw new SAXException(getNodeName() - + " node cannot have " + pNodeNameEnum + " child node!"); + if (pNodeNameEnum != INSTANCE) throw new SAXException(getNodeName() + " node cannot have " + + pNodeNameEnum + " child node!"); } /** |
From: Dave B. <bla...@us...> - 2013-10-29 12:50:02
|
Update of /cvsroot/sblim/jsr48-client In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv12502 Modified Files: NEWS Log Message: 2686 parseEXPPARAMVALUE allows 2+ children, prohibits 0 Index: NEWS =================================================================== RCS file: /cvsroot/sblim/jsr48-client/NEWS,v retrieving revision 1.390 retrieving revision 1.391 diff -u -d -r1.390 -r1.391 --- NEWS 29 Oct 2013 12:43:34 -0000 1.390 +++ NEWS 29 Oct 2013 12:50:00 -0000 1.391 @@ -1,5 +1,6 @@ Changes in HEAD ================ + 2686 parseEXPPARAMVALUE allows 2+ children, prohibits 0 2685 Element.getAttribute returns empty string if no attribute 2684 parseEXPMETHODRESPONSE has several issues 2683 KEYVALUE VALUETYPE optional, "string" default |