Patchwork macchanger: new package

login
register
mail settings
Submitter Simon Dawson
Date Oct. 16, 2012, 6:34 p.m.
Message ID <1350412488-17233-1-git-send-email-spdawson@gmail.com>
Download mbox | patch
Permalink /patch/191842/
State Superseded
Headers show

Comments

Simon Dawson - Oct. 16, 2012, 6:34 p.m.
From: Simon Dawson <spdawson@gmail.com>

Signed-off-by: Simon Dawson <spdawson@gmail.com>
---
 package/Config.in                |    1 +
 package/macchanger/Config.in     |    7 +++++++
 package/macchanger/macchanger.mk |   11 +++++++++++
 3 files changed, 19 insertions(+)
 create mode 100644 package/macchanger/Config.in
 create mode 100644 package/macchanger/macchanger.mk
Arnout Vandecappelle - Oct. 16, 2012, 6:55 p.m.
On 16/10/12 20:34, spdawson@gmail.com wrote:
> From: Simon Dawson<spdawson@gmail.com>
>
> Signed-off-by: Simon Dawson<spdawson@gmail.com>
[snip]
> diff --git a/package/macchanger/Config.in b/package/macchanger/Config.in
> new file mode 100644
> index 0000000..e26faa7
> --- /dev/null
> +++ b/package/macchanger/Config.in
> @@ -0,0 +1,7 @@
> +config BR2_PACKAGE_MACCHANGER
> +	bool "macchanger"
> +	help
> +	  A GNU/Linux utility for viewing/manipulating the MAC address of
> +	  network interfaces
> +
> +	  http://www.alobbs.com/macchanger

  Just for my info, what does this do that 'ip link set address xx:xx:xx:xx:xx:xx'
doesn't?

> diff --git a/package/macchanger/macchanger.mk b/package/macchanger/macchanger.mk
> new file mode 100644
> index 0000000..b1b9fff
> --- /dev/null
> +++ b/package/macchanger/macchanger.mk
> @@ -0,0 +1,11 @@
> +#############################################################
> +#
> +# macchanger
> +#
> +#############################################################
> +MACCHANGER_VERSION = 1.5.0
> +MACCHANGER_SITE = ftp://ftp.gnu.org/gnu/macchanger

MACCHANGER_SITE = $(BR2_GNU_MIRROR)/macchanger

  With this amendment:

Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Tested-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
  (build-test with a WCHAR-only internal powerpc toolchain)

> +MACCHANGER_LICENSE = GPLv2
> +MACCHANGER_LICENSE_FILES = COPYING
> +
> +$(eval $(autotools-package))
Simon Dawson - Oct. 16, 2012, 7:26 p.m.
Hi Arnout; thanks for the feedback.

On 16 October 2012 19:55, Arnout Vandecappelle <arnout@mind.be> wrote:
>  Just for my info, what does this do that 'ip link set address
> xx:xx:xx:xx:xx:xx'
> doesn't?

In addition to setting a specific MAC address, the tool can also be
used to set a random address. I don't think you can do that using ip.

>> +MACCHANGER_SITE = ftp://ftp.gnu.org/gnu/macchanger
>
>
> MACCHANGER_SITE = $(BR2_GNU_MIRROR)/macchanger
>
>  With this amendment:
>
> Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> Tested-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
>  (build-test with a WCHAR-only internal powerpc toolchain)

Okay; will fix this and resubmit.

Simon.
Yann E. MORIN - Oct. 16, 2012, 7:41 p.m.
Simon, All,

On Tuesday 16 October 2012 Simon Dawson wrote:
> On 16 October 2012 19:55, Arnout Vandecappelle <arnout@mind.be> wrote:
> >  Just for my info, what does this do that 'ip link set address
> > xx:xx:xx:xx:xx:xx'
> > doesn't?
> 
> In addition to setting a specific MAC address, the tool can also be
> used to set a random address. I don't think you can do that using ip.

Not with 'ip' only, but still possible:
  # MAC="$(dd if=/dev/urandom bs=6 count=1 2>/dev/null \
           |hexdump -e '5/1 "%0x:" "%0x"' )"
  # printf "%s\n" "${MAC}"
  b9:41:54:af:d9:f0
  # ip link set address "${MAC}"

UNIX-powa! And it's probably not the only possibility. ;-)

But yes, it's a bit more involved than simply calling a single executable.

Regards,
Yann E. MORIN.
Stefan Fröberg - Oct. 16, 2012, 10:57 p.m.
16.10.2012 21:55, Arnout Vandecappelle kirjoitti:
> On 16/10/12 20:34, spdawson@gmail.com wrote:
>> From: Simon Dawson<spdawson@gmail.com>
>>
>> Signed-off-by: Simon Dawson<spdawson@gmail.com>
> [snip]
>> diff --git a/package/macchanger/Config.in b/package/macchanger/Config.in
>> new file mode 100644
>> index 0000000..e26faa7
>> --- /dev/null
>> +++ b/package/macchanger/Config.in
>> @@ -0,0 +1,7 @@
>> +config BR2_PACKAGE_MACCHANGER
>> +    bool "macchanger"
>> +    help
>> +      A GNU/Linux utility for viewing/manipulating the MAC address of
>> +      network interfaces
>> +
>> +      http://www.alobbs.com/macchanger
>
>  Just for my info, what does this do that 'ip link set address
> xx:xx:xx:xx:xx:xx'
> doesn't?
>

Not much.

Besides setting MAC address to some specific value, it will let you to
autogenerate random
MAC address from within same device vendor, same physical device
category or completely random, bogust
MAC address.

So if you need to spoof MAC address when using aircrack-ng (which BTW, i
have as buildroot package here) or some
similar cracking tool then this might come handy.

But then again, and like you noted, there are already zillion of other
ways to change NIC MAC address ...

Best regards
Stefan

>> diff --git a/package/macchanger/macchanger.mk
>> b/package/macchanger/macchanger.mk
>> new file mode 100644
>> index 0000000..b1b9fff
>> --- /dev/null
>> +++ b/package/macchanger/macchanger.mk
>> @@ -0,0 +1,11 @@
>> +#############################################################
>> +#
>> +# macchanger
>> +#
>> +#############################################################
>> +MACCHANGER_VERSION = 1.5.0
>> +MACCHANGER_SITE = ftp://ftp.gnu.org/gnu/macchanger
>
> MACCHANGER_SITE = $(BR2_GNU_MIRROR)/macchanger
>
>  With this amendment:
>
> Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> Tested-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
>  (build-test with a WCHAR-only internal powerpc toolchain)
>
>> +MACCHANGER_LICENSE = GPLv2
>> +MACCHANGER_LICENSE_FILES = COPYING
>> +
>> +$(eval $(autotools-package))

Patch

diff --git a/package/Config.in b/package/Config.in
index d7b3db6..f8e83c6 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -573,6 +573,7 @@  endif
 source "package/links/Config.in"
 source "package/linphone/Config.in"
 source "package/lrzsz/Config.in"
+source "package/macchanger/Config.in"
 source "package/mii-diag/Config.in"
 source "package/mrouted/Config.in"
 source "package/msmtp/Config.in"
diff --git a/package/macchanger/Config.in b/package/macchanger/Config.in
new file mode 100644
index 0000000..e26faa7
--- /dev/null
+++ b/package/macchanger/Config.in
@@ -0,0 +1,7 @@ 
+config BR2_PACKAGE_MACCHANGER
+	bool "macchanger"
+	help
+	  A GNU/Linux utility for viewing/manipulating the MAC address of
+	  network interfaces
+
+	  http://www.alobbs.com/macchanger
diff --git a/package/macchanger/macchanger.mk b/package/macchanger/macchanger.mk
new file mode 100644
index 0000000..b1b9fff
--- /dev/null
+++ b/package/macchanger/macchanger.mk
@@ -0,0 +1,11 @@ 
+#############################################################
+#
+# macchanger
+#
+#############################################################
+MACCHANGER_VERSION = 1.5.0
+MACCHANGER_SITE = ftp://ftp.gnu.org/gnu/macchanger
+MACCHANGER_LICENSE = GPLv2
+MACCHANGER_LICENSE_FILES = COPYING
+
+$(eval $(autotools-package))