[Spacewalk-list] Creating perl script to use Spacewalk API butgetting error Could not find method create

Frey, Evan evan.frey at us.mizuho-sc.com
Tue Sep 15 13:59:10 UTC 2009


---- request ----
<?xml version="1.0"?>
<methodCall>
<methodName>errata.create</methodName>
<params>
<param><value><string>85527x08516ba59308fe8067f8cb90db52991a</string></value>
</param>
<param><value><string>topic</string></value></param>
<param><value><string>An updated dnsmasq package that fixes two security
issues is now available
for Red Hat Enterprise Linux 5.

This update has been rated as having important security impact by the Red
Hat Security Response Team.</string></value></param>
<param><value><string>advisory_name</string></value></param>
<param><value><string>RHSA-2009:1238</string></value></param>
<param><value><string>description</string></value></param>
<param><value><string>Dnsmasq is a lightweight and easy to configure DNS
forwarder and DHCP
server.

Core Security Technologies discovered a heap overflow flaw in dnsmasq when
the TFTP service is enabled (the "--enable-tftp" command line
option, or by
enabling "enable-tftp" in "/etc/dnsmasq.conf"). If the
configured tftp-root
is sufficiently long, and a remote user sends a request that sends a long
file name, dnsmasq could crash or, possibly, execute arbitrary code with
the privileges of the dnsmasq service (usually the unprivileged
"nobody"
user). (CVE-2009-2957)

A NULL pointer dereference flaw was discovered in dnsmasq when the TFTP
service is enabled. This flaw could allow a malicious TFTP client to crash
the dnsmasq service. (CVE-2009-2958)

Note: The default tftp-root is "/var/ftpd", which is short enough
to make
it difficult to exploit the CVE-2009-2957 issue; if a longer directory name
is used, arbitrary code execution may be possible. As well, the dnsmasq
package distributed by Red Hat does not have TFTP support enabled by
default.

All users of dnsmasq should upgrade to this updated package, which contains
a backported patch to correct these issues. After installing the updated
package, the dnsmasq service must be restarted for the update to take
effect.</string></value></param>
<param><value><string>solution</string></value></param>
<param><value><string>Upgrade where applicable</string></value></param>
<param><value><string>synopsis</string></value></param>
<param><value><string>Important: dnsmasq security
update</string></value></param>
<param><value><string>advisory_type</string></value></param>
<param><value><string>Security Advisory</string></value></param>
<param><value><string>references</string></value></param>
<param><value><string>http://www.redhat.com/security/updates/classification/#
important</string></value></param>
<param><value><string>notes</string></value></param>
<param><value><string></string></value></param>
<param><value><string>advisory_release</string></value></param>
<param><value><i4>1</i4></value></param>
<param><value><string>product</string></value></param>
<param><value><string>Red Hat</string></value></param>
<param><value><array><data>
</data></array></value>
</param>
<param><value><array><data>
</data></array></value>
</param>
<param><value><string>dnsmasq-2.45-1.1.el5_3.i386</string></value></param>
<param><value><string>dnsmasq-2.45-1.1.el5_3.ppc</string></value></param>
<param><value><string>dnsmasq-2.45-1.1.el5_3.x86_64</string></value></param>
<param><value><string>dnsmasq-2.45-1.1.el5_3.ia64</string></value></param>
<param><value><string>dnsmasq-2.45-1.1.el5_3.s390x</string></value></param>
<param><value><i4>1</i4></value></param>
<param><value><string>rhel-i386-server-5</string></value></param>
</params>
</methodCall>
---- response ----
Fault returned from XML RPC Server, fault code -1:
redstone.xmlrpc.XmlRpcFault: Could not find method create in class class
com.redhat.rhn.frontend.xmlrpc.errata.ErrataHandler
<?xml version="1.0"
encoding="UTF-8"?><methodResponse><fault><value><struct><member><name>faultCo
de</name><value><int>-1</int></value></member><member><name>faultString</name
><value><string>redstone.xmlrpc.XmlRpcFault: Could not find method create in
class class
com.redhat.rhn.frontend.xmlrpc.errata.ErrataHandler</string></value></member>
</struct></value></fault></methodResponse> 

-----Original Message-----
From: spacewalk-list-bounces at redhat.com
[mailto:spacewalk-list-bounces at redhat.com] On Behalf Of Jesus M. Rodriguez
Sent: Tuesday, September 15, 2009 9:09 AM
To: spacewalk-list at redhat.com
Subject: Re: [Spacewalk-list] Creating perl script to use Spacewalk API
butgetting error Could not find method create

On Tue, Sep 15, 2009 at 8:09 AM, Frey, Evan <evan.frey at us.mizuho-sc.com>
wrote:
> Actually, even with a hash I get the same error:
>
> Fault returned from XML RPC Server, fault code -1:
> redstone.xmlrpc.XmlRpcFault: Could not find method create in class 
> class com.redhat.rhn.frontend.xmlrpc.errata.ErrataHandler
>
> It appears like it can't find the create method in the errata class

Hrm ok, it's trying to find a match by method name AND parameter types. For
some reason it can't find a match for one of the types. We need to put your
client into debug mode so we can see the XML-RPC that it is sending to the
Spacewalk server.

If you are using Frontier::RPC then you can just turn on the debug flag when
you create the client:

   my $conn = new Frontier::Client(url => $host, debug => 1);

that will output the XML-RPC for the errata.create call. Then paste the
output to http://pastie.org/ and send the link to the list.

>
> Code looks like this:
>
>          my $RHNSynopsis = $RHNDetails{errata_synopsis};
>          my $RHNType = $RHNDetails{errata_type};
>          my $RHNTopic = $RHNDetails{errata_topic};
>        my $RHNDescription = $RHNDetails{errata_description};
>        my $RHNReferences = $RHNDetails{errata_references};
>        my $RHNNotes = $RHNDetails{errata_notes};
>        my $SWRelease = 1;
>        my $SWProduct = "Red Hat";
>        my $SWSolution = "Upgrade where applicable";
>        my @RHNBugs = [];
>        my @RHNKeywords = [];
>        my $SWPublish = 1;
>
>        my %Errata_Info = ("synopsis" => $RHNSynopsis,
>                                "advisory_name" => $ERRATA_NAME,
>                                "advisory_release" => $SWRelease,
>                                "advisory_type" => $RHNType,
>                                "product" => $SWProduct,
>                                "topic" => $RHNTopic,
>                                "description" => $RHNDescription,
>                                "references" => $RHNReferences,
>                                "notes" => $RHNNotes,
>                                "solution" => $SWSolution);
>
>
> $SWclient->call('errata.create',$SWsession,%Errata_Info, at RHNBugs, at RHNK
> eywords
> , at Packages,$SWPublish, at Channels);

jesus

_______________________________________________
Spacewalk-list mailing list
Spacewalk-list at redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list




More information about the Spacewalk-list mailing list