View on
MetaCPAN is shutting down
For details read Perl NOC. After June 25th this page will redirect to
Michael Schilli > Buffalo-G54-0.03 > Buffalo::G54



Annotate this POD

View/Report Bugs
Module Version: 0.03   Source  


Buffalo::G54 - Limited scraping API for Buffalo WBR2-G54 routers


    use Buffalo::G54;


This module implements a limited API to control a Buffalo WBR2-G54 router by scraping its Web interface.


Currently, only the following methods are implemented:

my $buf = Buffalo::G54->new()



Connects to the router's Web interface, takes the following key value pairs:

    ip       => "",
    user     => "root",
    password => "topsecret!",

Returns 1 if the router's Web interface responded properly, and undef otherwise.


Ask the router for the version of its firmware. Returns something like "WBR2-G54 Ver.2.21" if successful, or undef on failure.

Reboot the router.


Switch the router's wireless network on or off -- or query its status.

To query the status of the router's wireless network, call wireless() without parameters:

      # Returns "on" or "off"
    my $status = $buf->wireless();

It will return "on" or "off", or undef if an error occurred.

      # Switch wireless off if it's on
    if($buf->wireless() eq "on") {

To switch the wireless network on or off, pass a $status value of "on" or "off" to the wireless() method.

Note that switching the wireless network on and off requires having set up the wireless network in the first place. wireless() is just going to toggle the on/off switch, it doesn't configure the SSID, encryption and other important settings.


Turns the DHCP server on or off or queries its status:


    if($buf->dhcp() eq "on") {
        print "dhcp is on!\n";


Copyright 2006 by Mike Schilli, all rights reserved. This program is free software, you can redistribute it and/or modify it under the same terms as Perl itself.


2006, Mike Schilli <>

syntax highlighting: