[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[no subject]
- <!--x-content-type: text/plain -->
- <!--x-date: Fri Feb 11 08:57:27 2005 -->
- <!--x-from-r13: psbjyre ng bhgcbfgfragvary.pbz (Quevfgbcure Tbjyre) -->
- <!--x-message-id: [email protected] -->
- <!--x-reference: [email protected] -->
- <!--x-reference: [email protected] -->
- <!--x-reference: [email protected] -->
- <!--x-reference: [email protected] -->
- <!--x-reference: [email protected] --> "http://www.w3.org/TR/html4/loose.dtd">
- <!--x-subject: [ale] Implementing XML-RPC -->
- <li><em>date</em>: Fri Feb 11 08:57:27 2005</li>
- <li><em>from</em>: cfowler at outpostsentinel.com (Christopher Fowler)</li>
- <li><em>in-reply-to</em>: <<a href="msg00396.html">[email protected]</a>></li>
- <li><em>references</em>: <<a href="msg00381.html">[email protected]</a>> <<a href="msg00383.html">[email protected]</a>> <<a href="msg00387.html">[email protected]</a>> <<a href="msg00388.html">[email protected]</a>> <<a href="msg00396.html">[email protected]</a>></li>
- <li><em>subject</em>: [ale] Implementing XML-RPC</li>
Has anyone used the Frontier client?
--- Test Code ---
use Frontier::Client;
$server = Frontier::Client->new( debug => 1, url =>
'<a rel="nofollow" href="https://192.168.2.120/cgi-bin/xml-rpc">https://192.168.2.120/cgi-bin/xml-rpc</a>' );
$result = $server->call('restart', ("now"));
print "$result\n";
--- Test Code ---
Here is the problem. It works fine when the code is in stand alone
debug mode. But I'm not doing any authentication. Instead of using
a string as the 'url' in the contstructor I need to use LWP to login to
the site to get a valid cookie. If I place this code in the production
site without a valid cookie I'll simply be redirected to
'/cgi-bin/login' . I'm not really planning on using Frontier for
production code. The PERL in this case is all test code. J2EE will be
doing the interfacing with the remote device. I'll eventually create a
device object in Perl that will use XML-RPC to execute remote commands
but that is not important now. I'm just curious as to how I can use
Frontier with my device since all pages on my device require form based
authentication.
Thanks,
Chris
On Fri, 2005-02-11 at 08:13, Fletch wrote:
> >>>>> "Christopher" == Christopher Fowler <cfowler at outpostsentinel.com> writes:
>
> [...]
>
> Christopher> I think that is right. I can not seem to find info
> Christopher> on how to return errors. Simply like what XML do I
> Christopher> return if for example a method is called that does
> Christopher> not exist on the server?
>
> I can't recall offhand (I want to say it's something like
> <error><code>#</code><message>...</message></error>), but if you
> install the Perl RPC::XML module (or use the Python one which is stock
> post 2.3 I think, or the Ruby one that's stock post 1.8.2 :) and send
> a simple server a bogus request you should be able to see what those
> send back.
</pre>
<!--X-Body-of-Message-End-->
<!--X-MsgBody-End-->
<!--X-Follow-Ups-->
<hr>
<ul><li><strong>Follow-Ups</strong>:
<ul>
<li><strong><a name="00402" href="msg00402.html">[ale] Implementing XML-RPC</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
</ul></li></ul>
<!--X-Follow-Ups-End-->
<!--X-References-->
<ul><li><strong>References</strong>:
<ul>
<li><strong><a name="00381" href="msg00381.html">[ale] Implementing XML-RPC</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
<li><strong><a name="00383" href="msg00383.html">[ale] Implementing XML-RPC</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
<li><strong><a name="00387" href="msg00387.html">[ale] Implementing XML-RPC</a></strong>
<ul><li><em>From:</em> fletch at phydeaux.org (Fletch)</li></ul></li>
<li><strong><a name="00388" href="msg00388.html">[ale] Implementing XML-RPC</a></strong>
<ul><li><em>From:</em> cfowler at outpostsentinel.com (Christopher Fowler)</li></ul></li>
<li><strong><a name="00396" href="msg00396.html">[ale] Implementing XML-RPC</a></strong>
<ul><li><em>From:</em> fletch at phydeaux.org (Fletch)</li></ul></li>
</ul></li></ul>
<!--X-References-End-->
<!--X-BotPNI-->
<ul>
<li>Prev by Date:
<strong><a href="msg00398.html">[ale] more google fun</a></strong>
</li>
<li>Next by Date:
<strong><a href="msg00400.html">[ale] Delivery service mail</a></strong>
</li>
<li>Previous by thread:
<strong><a href="msg00396.html">[ale] Implementing XML-RPC</a></strong>
</li>
<li>Next by thread:
<strong><a href="msg00402.html">[ale] Implementing XML-RPC</a></strong>
</li>
<li>Index(es):
<ul>
<li><a href="maillist.html#00399"><strong>Date</strong></a></li>
<li><a href="threads.html#00399"><strong>Thread</strong></a></li>
</ul>
</li>
</ul>
<!--X-BotPNI-End-->
<!--X-User-Footer-->
<!--X-User-Footer-End-->
</body>
</html>