You are not logged in.

#1 2009-11-08 14:26:06

Lexion
Member
Registered: 2008-03-23
Posts: 510

wlanmgr: manages wireless connections

wlanmgr does the basic tasks related to wifi: list available networks, make network profiles, and connect to them.  It also acts as a dsniff/tcpdump/urlsnarf wrapper, allowing you to test network security.  It also displays network bandwidth usage by host name.

It does this using iwlist for listing, netcfg for making and using profiles (it has a netcfg profile generator), and iftop for the bandwidth monitor.  I rely heavily on them, so I thank their devs.

I made a PKGBUILD, but it is my first, so please give me advice on how to make it better (I'm almost certain it's not): http://onebluecat.net/wlanmgr/wlanmgr.tar.gz

And here is the source code: http://onebluecat.net/wlanmgr/wlanmgr-src.tar.gz

Enjoy.


urxvtc / wmii / zsh / configs / onebluecat.net
Arch will not hold your hand

Offline

#2 2009-11-08 14:36:52

knedlyk
Member
From: L'viv, Ukraine
Registered: 2009-04-14
Posts: 163
Website

Re: wlanmgr: manages wireless connections

Where is wlanmgr.install from http://onebluecat.net/wlanmgr/wlanmgr.tar.gz? BTW, why your build try to install binaries immediately? General user must to be root to do it. I mean these lines:
    cp $srcdir/wlanmgr /usr/bin/wlanmgr
    chmod +x /usr/bin/wlanmgr
    cp $srcdir/wlanmgrrc.default /etc/wlanmgrrc.example

It should be something like
    mkdir -p $pkgdir/usr/bin/
    mkdir $pkgdir/etc/
    install -m 755 $srcdir/wlanmgr $pkgdir/usr/bin/wlanmgr
    chmod +x /usr/bin/wlanmgr
    cp $srcdir/wlanmgrrc.default $pkgdir/etc/wlanmgrrc.example

Last edited by knedlyk (2009-11-08 14:49:32)

Offline

#3 2009-11-08 18:49:19

zenlord
Member
From: Belgium
Registered: 2006-05-24
Posts: 1,221
Website

Re: wlanmgr: manages wireless connections

Build failed.

First I had to get the wlanmgr.install from the sources and cp it in the same folder as the PKGBUILD, and next it resolved the dependencies fine. This is the error I get:
---------------------------
cp: kan het normale bestand '/usr/bin/wlanmgr' niet aanmaken: Toegang geweigerd (access denied)
chmod: kan geen toegang krijgen tot '/usr/bin/wlanmgr': Bestand of map bestaat niet (folder or file doesn't exist)
cp: kan het normale bestand '/etc/wlanmgrrc.example' niet aanmaken: Toegang geweigerd (access denied)
==> ERROR: Build Failed.
    Aborting...
-----------------------

Maybe you could enter this package in AUR?

Zl.

Offline

#4 2009-11-09 12:56:58

Lexion
Member
Registered: 2008-03-23
Posts: 510

Re: wlanmgr: manages wireless connections

I've fixed the problems, it should work now.  I'll put it into the AUR when I get some time (probably later today).


urxvtc / wmii / zsh / configs / onebluecat.net
Arch will not hold your hand

Offline

#5 2009-11-11 11:51:13

zenlord
Member
From: Belgium
Registered: 2006-05-24
Posts: 1,221
Website

Re: wlanmgr: manages wireless connections

Once the package is in AUR, I'll gladly test it for you.

Offline

#6 2009-11-12 13:13:03

knedlyk
Member
From: L'viv, Ukraine
Registered: 2009-04-14
Posts: 163
Website

Re: wlanmgr: manages wireless connections

Me too

Offline

#7 2009-11-12 22:10:32

Lexion
Member
Registered: 2008-03-23
Posts: 510

Re: wlanmgr: manages wireless connections

It's now AUR: http://aur.archlinux.org/packages.php?ID=31957

Sorry for the delay, but I had to meet a deadline with something else...


urxvtc / wmii / zsh / configs / onebluecat.net
Arch will not hold your hand

Offline

#8 2009-11-13 08:23:49

lswest
Member
From: Munich, Germany
Registered: 2008-06-14
Posts: 456
Website

Re: wlanmgr: manages wireless connections

I just tried installing wlanmgr to test it out, yet the PKGBUILD ends up only copying the wlanmgrrc.example file to /etc/ (wlanmgr doesn't exist anywhere on the filesystem after installation).  I've got no experience with PKGBUILDs, so I can't offer any suggestions on what could be wrong, but I just thought I'd bring it to your attention.

The errors that makepkg throws are these:

install: omitting directory `/home/lswest/Packages/Testing/wlanmgr/src/wlanmgr'
chmod: cannot access `/usr/bin/wlanmgr': No such file or directory

For the chmod error, I believe you need a $pkgdir in front of /usr/bin/wlanmgr

Hope that helps,
Lswest

*edit*
I played around with the PKGBUILD and I seem to have gotten it working (changes marked in bold).

# Contributor: Lexion <lexion@archlinux.us>
pkgname=wlanmgr
pkgver=0.1
pkgrel=1
pkgdesc="Wlanmgr is a set of utils for using and/or hacking wireless networks"
arch=('i686' 'x86_64')
url="onebluecat.net/wlanmgr"
license=('GPL')
install=wlanmgr.install
depends=('netcfg' 'dsniff' 'iftop')
provides=('wlanmgr')
conflicts=('wlanmgr')

build() {
    wget $url/wlanmgr -O $srcdir/wlanmgr
    wget $url/wlanmgrrc.default -O $srcdir/wlanmgrrc.default

    mkdir -p $pkgdir/usr/bin
    mkdir -p $pkgdir/etc
    install -D -m 755 $srcdir/wlanmgr $pkgdir/usr/bin/wlanmgr
    chmod +x $pkgdir/usr/bin/wlanmgr
    cp $srcdir/wlanmgrrc.default $pkgdir/etc/wlanmgrrc.example
}

Lines changed are:

install -D -m 755 $srcdir/wlanmgr $pkgdir/usr/bin/wlanmgr
    chmod +x $pkgdir/usr/bin/wlanmgr

Last edited by lswest (2009-11-13 08:48:46)


Lswest <- the first letter of my username is a lowercase "L".
"...the Linux philosophy is "laugh in the face of danger". Oops. Wrong one. "Do it yourself". That's it." - Linus Torvalds

Offline

#9 2009-11-13 13:19:37

Lexion
Member
Registered: 2008-03-23
Posts: 510

Re: wlanmgr: manages wireless connections

should be fixed, thanks for the help.


urxvtc / wmii / zsh / configs / onebluecat.net
Arch will not hold your hand

Offline

#10 2009-11-13 13:21:40

lswest
Member
From: Munich, Germany
Registered: 2008-06-14
Posts: 456
Website

Re: wlanmgr: manages wireless connections

No problem smile I enjoyed having something to do during the slow part of my workday.


Lswest <- the first letter of my username is a lowercase "L".
"...the Linux philosophy is "laugh in the face of danger". Oops. Wrong one. "Do it yourself". That's it." - Linus Torvalds

Offline

#11 2009-11-13 18:07:00

Pank
Member
From: IT
Registered: 2009-06-13
Posts: 371

Re: wlanmgr: manages wireless connections

I actually like your script, however I have a few comments:

1. You should only upload the PKGBUILD and the install file. At the moment you uploaded binaries. Please use

makepkg --source

It seems nmap is missing from the dependencies:

╰─[19:01:06]> sudo wlanmgr peers
/usr/bin/wlanmgr: line 138: nmap: command not found
╰─[19:01:13]> pkgfile nmap
extra/nmap

You might want to consider wlanmgr -h for help (as well as wlanmgr help). It would be nice if one could get a description of all commands at once rather than having to to do help [command].

edit:

╰─[19:12:47]> sudo wlanmgr netusage
handing over to iftop
interface: eth0
Unable to get IP address for interface: eth0
ioctl(SIOCGIFADDR): Cannot assign requested address
MAC address is: 00:16:d3:3b:66:47
pcap_open_live(eth0): eth0: That device is not up

Shouldn't it be using wlan0 rather than eth0?

Thanks,
Rasmus

Last edited by Pank (2009-11-13 18:14:44)


Arch x64 on Thinkpad X200s/W530

Offline

#12 2009-11-13 18:17:16

Lexion
Member
Registered: 2008-03-23
Posts: 510

Re: wlanmgr: manages wireless connections

I'm sorry, but I forgot to upload to AUR (I only uploaded to my server).  smile


urxvtc / wmii / zsh / configs / onebluecat.net
Arch will not hold your hand

Offline

#13 2009-11-13 18:33:14

Pank
Member
From: IT
Registered: 2009-06-13
Posts: 371

Re: wlanmgr: manages wireless connections

You are still missing nmap smile


Arch x64 on Thinkpad X200s/W530

Offline

#14 2009-11-15 13:44:15

Lexion
Member
Registered: 2008-03-23
Posts: 510

Re: wlanmgr: manages wireless connections

geez! I can't seem to get the hang of this.

I added nmap to the dep list.


urxvtc / wmii / zsh / configs / onebluecat.net
Arch will not hold your hand

Offline

Board footer

Powered by FluxBB