[rhmessaging-commits] rhmessaging commits: r4412 - store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store.

rhmessaging-commits at lists.jboss.org rhmessaging-commits at lists.jboss.org
Tue Nov 9 19:46:08 EST 2010


Author: tedross
Date: 2010-11-09 19:46:08 -0500 (Tue, 09 Nov 2010)
New Revision: 4412

Modified:
   store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Journal.cpp
   store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Journal.h
   store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Store.cpp
   store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Store.h
Log:
Re-generated qmf files.


Modified: store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Journal.cpp
===================================================================
--- store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Journal.cpp	2010-11-08 14:17:48 UTC (rev 4411)
+++ store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Journal.cpp	2010-11-10 00:46:08 UTC (rev 4412)
@@ -689,7 +689,7 @@
     buf.getRawData(_sBuf, _bufLen);
 }
 
-void Journal::doMethod (string& methodName, const string& inStr, string& outStr)
+void Journal::doMethod (string& methodName, const string& inStr, string& outStr, const string& userId)
 {
     Manageable::status_t status = Manageable::STATUS_UNKNOWN_METHOD;
     std::string          text;
@@ -709,7 +709,11 @@
         _matched = true;
         ArgsJournalExpand ioArgs;
         ioArgs.i_by = inBuf.getLong();
-        status = coreObject->ManagementMethod (METHOD_EXPAND, ioArgs, text);
+        bool allow = coreObject->AuthorizeMethod(METHOD_EXPAND, ioArgs, userId);
+        if (allow)
+            status = coreObject->ManagementMethod (METHOD_EXPAND, ioArgs, text);
+        else
+            status = Manageable::STATUS_FORBIDDEN;
         outBuf.putLong        (status);
         outBuf.putMediumString(::qpid::management::Manageable::StatusText (status, text));
     }
@@ -868,7 +872,7 @@
 
 }
 
-void Journal::doMethod (string& methodName, const ::qpid::types::Variant::Map& inMap, ::qpid::types::Variant::Map& outMap)
+void Journal::doMethod (string& methodName, const ::qpid::types::Variant::Map& inMap, ::qpid::types::Variant::Map& outMap, const string& userId)
 {
     Manageable::status_t status = Manageable::STATUS_UNKNOWN_METHOD;
     std::string          text;
@@ -880,7 +884,11 @@
         if ((_i = inMap.find("by")) != inMap.end()) {
             ioArgs.i_by = _i->second;
         }
-        status = coreObject->ManagementMethod (METHOD_EXPAND, ioArgs, text);
+        bool allow = coreObject->AuthorizeMethod(METHOD_EXPAND, ioArgs, userId);
+        if (allow)
+            status = coreObject->ManagementMethod (METHOD_EXPAND, ioArgs, text);
+        else
+            status = Manageable::STATUS_FORBIDDEN;
         outMap["_status_code"] = (uint32_t) status;
         outMap["_status_text"] = ::qpid::management::Manageable::StatusText(status, text);
         return;

Modified: store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Journal.h
===================================================================
--- store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Journal.h	2010-11-08 14:17:48 UTC (rev 4411)
+++ store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Journal.h	2010-11-10 00:46:08 UTC (rev 4412)
@@ -134,7 +134,8 @@
     void mapDecodeValues(const ::qpid::types::Variant::Map& map);
     void doMethod(std::string&           methodName,
                   const ::qpid::types::Variant::Map& inMap,
-                  ::qpid::types::Variant::Map& outMap);
+                  ::qpid::types::Variant::Map& outMap,
+                  const std::string& userId);
     std::string getKey() const;
 
     uint32_t writePropertiesSize() const;
@@ -143,7 +144,8 @@
     void writeStatistics(std::string& buf, bool skipHeaders = false);
     void doMethod(std::string& methodName,
                   const std::string& inBuf,
-                  std::string& outBuf);
+                  std::string& outBuf,
+                  const std::string& userId);
 
 
     writeSchemaCall_t getWriteSchemaCall() { return writeSchema; }

Modified: store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Store.cpp
===================================================================
--- store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Store.cpp	2010-11-08 14:17:48 UTC (rev 4411)
+++ store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Store.cpp	2010-11-10 00:46:08 UTC (rev 4412)
@@ -452,7 +452,7 @@
     buf.getRawData(_sBuf, _bufLen);
 }
 
-void Store::doMethod (string&, const string&, string& outStr)
+void Store::doMethod (string&, const string&, string& outStr, const string&)
 {
     Manageable::status_t status = Manageable::STATUS_UNKNOWN_METHOD;
     std::string          text;
@@ -580,7 +580,7 @@
 
 }
 
-void Store::doMethod (string&, const ::qpid::types::Variant::Map&, ::qpid::types::Variant::Map& outMap)
+void Store::doMethod (string&, const ::qpid::types::Variant::Map&, ::qpid::types::Variant::Map& outMap, const string&)
 {
     Manageable::status_t status = Manageable::STATUS_UNKNOWN_METHOD;
     std::string          text;

Modified: store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Store.h
===================================================================
--- store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Store.h	2010-11-08 14:17:48 UTC (rev 4411)
+++ store/trunk/cpp/lib/gen/qmf/com/redhat/rhm/store/Store.h	2010-11-10 00:46:08 UTC (rev 4412)
@@ -104,7 +104,8 @@
     void mapDecodeValues(const ::qpid::types::Variant::Map& map);
     void doMethod(std::string&           methodName,
                   const ::qpid::types::Variant::Map& inMap,
-                  ::qpid::types::Variant::Map& outMap);
+                  ::qpid::types::Variant::Map& outMap,
+                  const std::string& userId);
     std::string getKey() const;
 
     uint32_t writePropertiesSize() const;
@@ -113,7 +114,8 @@
     void writeStatistics(std::string& buf, bool skipHeaders = false);
     void doMethod(std::string& methodName,
                   const std::string& inBuf,
-                  std::string& outBuf);
+                  std::string& outBuf,
+                  const std::string& userId);
 
 
     writeSchemaCall_t getWriteSchemaCall() { return writeSchema; }



More information about the rhmessaging-commits mailing list