{"_id":"node-macaddress","_rev":"552353","name":"node-macaddress","description":"Get the MAC addresses (hardware addresses) of the hosts network interfaces.","dist-tags":{"latest":"0.2.4"},"maintainers":[{"name":"scravy","email":"julian@scravy.de"}],"time":{"modified":"2024-06-26T04:05:34.000Z","created":"2015-03-30T18:35:38.113Z","0.2.4":"2015-04-03T22:42:30.178Z","0.2.2":"2015-04-02T20:05:37.813Z","0.2.1":"2015-04-02T20:04:45.543Z","0.1.3":"2015-04-02T20:03:42.101Z","0.2.0":"2015-04-02T20:02:09.848Z","0.1.2":"2015-04-02T02:26:47.129Z","0.1.1":"2015-03-30T19:15:19.464Z","0.1.0":"2015-03-30T18:35:38.113Z"},"users":{"suncn":true,"invelo":true},"author":{"name":"Julian Fleischer"},"repository":{"type":"git","url":"https://github.com/scravy/node-macaddress.git"},"versions":{"0.2.4":{"name":"node-macaddress","version":"0.2.4","description":"Get the MAC addresses (hardware addresses) of the hosts network interfaces.","main":"index.js","scripts":{"test":"node test.js"},"repository":{"type":"git","url":"https://github.com/scravy/node-macaddress.git"},"keywords":["mac","mac-address","hardware-address","network","system"],"author":{"name":"Julian Fleischer"},"license":"MIT","bugs":{"url":"https://github.com/scravy/node-macaddress/issues"},"homepage":"https://github.com/scravy/node-macaddress","dependencies":{"async":"^0.9.0"},"devDependencies":{"gulp":"^3.8.11","gulp-jshint":"^1.9.4"},"gitHead":"36a01ae53ddbe0d7648fa6678be34dad6dba1c86","_id":"node-macaddress@0.2.4","_shasum":"8dc3927d47c266fba0b0d8ce6db1c3da8eb7cc60","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.1","_npmUser":{"name":"scravy","email":"julian@scravy.de"},"maintainers":[{"name":"scravy","email":"julian@scravy.de"}],"dist":{"shasum":"8dc3927d47c266fba0b0d8ce6db1c3da8eb7cc60","tarball":"http://registry-npm.ywwl.com/node-macaddress/download/node-macaddress-0.2.4.tgz","integrity":"sha512-bATzyygsv634+tFeqUs3FHnxeXBkJ2PEocpU2Jnx2ORDNZ5GXfTwDdchGyzWIc7CC8BjCWtEjR75EfPp0CPgVQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDYTrkmSw1jpEW4piq4ZDpyrBCoZ+2RIH9B4A6uT025IAIhAIT2wF9y63YMh1lewEhekfcZ/MyITbCR6kUs31xDoft8"}],"size":4252,"noattachment":false,"key":"/node-macaddress/-/node-macaddress-0.2.4.tgz"},"deprecated":"'node-macaddress' was renamed to just 'macaddress', please use that one.","directories":{},"publish_time":1428100950178,"_cnpm_publish_time":1428100950178},"0.2.2":{"name":"node-macaddress","version":"0.2.2","description":"Get the MAC addresses (hardware addresses) of the hosts network interfaces.","main":"index.js","scripts":{"test":"node test.js"},"repository":{"type":"git","url":"https://github.com/scravy/node-macaddress.git"},"keywords":["mac","mac-address","hardware-address","network","system"],"author":{"name":"Julian Fleischer"},"license":"MIT","bugs":{"url":"https://github.com/scravy/node-macaddress/issues"},"homepage":"https://github.com/scravy/node-macaddress","dependencies":{"async":"^0.9.0"},"devDependencies":{"gulp":"^3.8.11","gulp-jshint":"^1.9.4"},"gitHead":"05671f6ea558959bc98f264ac630591df8a355a8","_id":"node-macaddress@0.2.2","_shasum":"df564a53e129fc54ed98e71b5a21089d422a7f1d","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.1","_npmUser":{"name":"scravy","email":"julian@scravy.de"},"maintainers":[{"name":"scravy","email":"julian@scravy.de"}],"dist":{"shasum":"df564a53e129fc54ed98e71b5a21089d422a7f1d","tarball":"http://registry-npm.ywwl.com/node-macaddress/download/node-macaddress-0.2.2.tgz","integrity":"sha512-gnc+O29rKDvlNTQkxGOiJm8ua11FT9puEpOJwBjcweGoSVQPfShawWLgmm0Xg63D6IcI1lCUB7YmyRIso/q+3w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBGpwXZBsvvRIvjZTSexGTvOFEsXHic1Z7WdjBgreZWuAiEA9n+bMPoIfgdbpAeIv+FRIbHYmwdq+OuT0pTcE6N5+QE="}],"size":4146,"noattachment":false,"key":"/node-macaddress/-/node-macaddress-0.2.2.tgz"},"deprecated":"'node-macaddress' was renamed to just 'macaddress', please use that one.","directories":{},"publish_time":1428005137813,"_cnpm_publish_time":1428005137813},"0.2.1":{"name":"node-macaddress","version":"0.2.1","description":"Get the MAC addresses (hardware addresses) of the hosts network interfaces.","main":"index.js","scripts":{"test":"node test.js"},"repository":{"type":"git","url":"https://github.com/scravy/node-macaddress.git"},"keywords":["mac","mac-address","hardware-address","network","system"],"author":{"name":"Julian Fleischer"},"license":"MIT","bugs":{"url":"https://github.com/scravy/node-macaddress/issues"},"homepage":"https://github.com/scravy/node-macaddress","dependencies":{"async":"^0.9.0"},"devDependencies":{"gulp":"^3.8.11","gulp-jshint":"^1.9.4"},"gitHead":"c68669e26e7aa7b35aa1abe4cb1190cefa8b8b28","_id":"node-macaddress@0.2.1","_shasum":"170576a706c8606e1e99b3c22137f6b89827ea37","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.1","_npmUser":{"name":"scravy","email":"julian@scravy.de"},"maintainers":[{"name":"scravy","email":"julian@scravy.de"}],"dist":{"shasum":"170576a706c8606e1e99b3c22137f6b89827ea37","tarball":"http://registry-npm.ywwl.com/node-macaddress/download/node-macaddress-0.2.1.tgz","integrity":"sha512-xUw/57cn1sZB34qffSFll/XDBT2Fi0ue86fCUOj/9rb05VKYN3fYNh18k+Y7sdvQCGKR15x8y/sKz4xqMCATaA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEOOWUWJO5lqaLkpb10Tsesuv8a4jGmmJ8X9BSDSynQcAiB4Va0QjswRPVEpV41uWXCGujqym/dgxaWZ36dLtk5RVA=="}],"size":4164,"noattachment":false,"key":"/node-macaddress/-/node-macaddress-0.2.1.tgz"},"deprecated":"'node-macaddress' was renamed to just 'macaddress', please use that one.","directories":{},"publish_time":1428005085543,"_cnpm_publish_time":1428005085543},"0.1.3":{"name":"node-macaddress","version":"0.1.3","description":"Get the MAC addresses (hardware addresses) of the hosts network interfaces.","main":"index.js","scripts":{"test":"node test.js"},"repository":{"type":"git","url":"https://github.com/scravy/node-macaddress.git"},"keywords":["mac","mac-address","hardware-address","network","system"],"author":{"name":"Julian Fleischer"},"license":"MIT","bugs":{"url":"https://github.com/scravy/node-macaddress/issues"},"homepage":"https://github.com/scravy/node-macaddress","dependencies":{"async":"^0.9.0"},"devDependencies":{"gulp":"^3.8.11","gulp-jshint":"^1.9.4"},"gitHead":"c68669e26e7aa7b35aa1abe4cb1190cefa8b8b28","_id":"node-macaddress@0.1.3","_shasum":"167a857ea479669925fd8e0cdef2c536b95db062","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.1","_npmUser":{"name":"scravy","email":"julian@scravy.de"},"maintainers":[{"name":"scravy","email":"julian@scravy.de"}],"dist":{"shasum":"167a857ea479669925fd8e0cdef2c536b95db062","tarball":"http://registry-npm.ywwl.com/node-macaddress/download/node-macaddress-0.1.3.tgz","integrity":"sha512-M6FDLlNBylJGpb88uEN4IruJhHELhMjYGWc/VuhoGdlTDbZEsgSAPRtRJB0RHU0hJbxXrvfsBb6NoxnBvT1itw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCGwk6AttPXAg1LFytFN9SGoGOE2mQpDEGzEUqWjkcTDgIhALKeXDVd0qAiQFuUpkxtEGSBnyVCWCxSvo86IZgPD4eZ"}],"size":4150,"noattachment":false,"key":"/node-macaddress/-/node-macaddress-0.1.3.tgz"},"deprecated":"'node-macaddress' was renamed to just 'macaddress', please use that one.","directories":{},"publish_time":1428005022101,"_cnpm_publish_time":1428005022101},"0.2.0":{"name":"node-macaddress","version":"0.2.0","description":"Get the MAC addresses (hardware addresses) of the hosts network interfaces.","main":"index.js","scripts":{"test":"node test.js"},"repository":{"type":"git","url":"https://github.com/scravy/node-macaddress.git"},"keywords":["mac","mac-address","hardware-address","network","system"],"author":{"name":"Julian Fleischer"},"license":"MIT","bugs":{"url":"https://github.com/scravy/node-macaddress/issues"},"homepage":"https://github.com/scravy/node-macaddress","dependencies":{"async":"^0.9.0"},"devDependencies":{"gulp":"^3.8.11","gulp-jshint":"^1.9.4"},"gitHead":"c68669e26e7aa7b35aa1abe4cb1190cefa8b8b28","_id":"node-macaddress@0.2.0","_shasum":"9fb3a24aa1d70eb792aeb97d32ffcf69e44981b7","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.1","_npmUser":{"name":"scravy","email":"julian@scravy.de"},"maintainers":[{"name":"scravy","email":"julian@scravy.de"}],"dist":{"shasum":"9fb3a24aa1d70eb792aeb97d32ffcf69e44981b7","tarball":"http://registry-npm.ywwl.com/node-macaddress/download/node-macaddress-0.2.0.tgz","integrity":"sha512-CyYvn5d4vVRt56YQHhGHzPSd85rFaKJq1mH1svT6fGkx2WVMwDZ5YahHHAHvRoPciomO6OXCkYaaFGRdsJEF0w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCMjwXqIiyiH4gnMYMKXuL1R7HwkG7+8CfdbrFweqtiowIhAKci/O3hRu9HpSw5fVY4BkBnV3tPvMl7PGsnIBh7oQq+"}],"size":4160,"noattachment":false,"key":"/node-macaddress/-/node-macaddress-0.2.0.tgz"},"deprecated":"'node-macaddress' was renamed to just 'macaddress', please use that one.","directories":{},"publish_time":1428004929848,"_cnpm_publish_time":1428004929848},"0.1.2":{"name":"node-macaddress","version":"0.1.2","description":"Get the MAC addresses (hardware addresses) of the hosts network interfaces.","main":"index.js","scripts":{"test":"node test.js"},"repository":{"type":"git","url":"https://github.com/scravy/node-macaddress.git"},"keywords":["mac","mac-address","hardware-address","network","system"],"author":{"name":"Julian Fleischer"},"license":"MIT","bugs":{"url":"https://github.com/scravy/node-macaddress/issues"},"homepage":"https://github.com/scravy/node-macaddress","dependencies":{"async":"^0.9.0"},"devDependencies":{"gulp":"^3.8.11","gulp-jshint":"^1.9.4"},"gitHead":"729d19634c6eafec3de95b7ad0b549bfa33b6705","_id":"node-macaddress@0.1.2","_shasum":"95c3f600201987637c5ccdf3f9ff0345a698e1e4","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.1","_npmUser":{"name":"scravy","email":"julian@scravy.de"},"maintainers":[{"name":"scravy","email":"julian@scravy.de"}],"dist":{"shasum":"95c3f600201987637c5ccdf3f9ff0345a698e1e4","tarball":"http://registry-npm.ywwl.com/node-macaddress/download/node-macaddress-0.1.2.tgz","integrity":"sha512-jFMMpx8iDW/QB0xCA+wzMZALbuMbPErWw13BOLmjCh851iUqYHfe+CPgOHLuE61UvNzaCKW81BiFvyRdUWDxmw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCwDmQ9QSpLkIEpznVQsSNtBwhDgsVBfID6Nqhme4wpkgIhAO8aQsYNlzYXqMPFXMIznGbsqPdRYdeUeUvrYtOPuVSU"}],"size":4178,"noattachment":false,"key":"/node-macaddress/-/node-macaddress-0.1.2.tgz"},"deprecated":"'node-macaddress' was renamed to just 'macaddress', please use that one.","directories":{},"publish_time":1427941607129,"_cnpm_publish_time":1427941607129},"0.1.1":{"name":"node-macaddress","version":"0.1.1","description":"Get the MAC addresses (hardware addresses) of the hosts network interfaces.","main":"index.js","scripts":{"test":"node test.js"},"repository":{"type":"git","url":"https://github.com/scravy/node-macaddress.git"},"keywords":["mac","mac-address","hardware-address","network","system"],"author":{"name":"Julian Fleischer"},"license":"MIT","bugs":{"url":"https://github.com/scravy/node-macaddress/issues"},"homepage":"https://github.com/scravy/node-macaddress","dependencies":{"async":"^0.9.0"},"devDependencies":{"gulp":"^3.8.11","gulp-jshint":"^1.9.4"},"gitHead":"d6a286282cc6da87a805c55965b17aa0499bb9ff","_id":"node-macaddress@0.1.1","_shasum":"433d780fd514ba688cb2e37853571401f7e213ca","_from":".","_npmVersion":"2.1.10","_nodeVersion":"0.10.26","_npmUser":{"name":"scravy","email":"julian@scravy.de"},"maintainers":[{"name":"scravy","email":"julian@scravy.de"}],"dist":{"shasum":"433d780fd514ba688cb2e37853571401f7e213ca","tarball":"http://registry-npm.ywwl.com/node-macaddress/download/node-macaddress-0.1.1.tgz","integrity":"sha512-X9z7xnrO1Cwu/Dpwyog/kJmNBF4v0h89m90GwpRXcNcagL3iYnYCuHNkibA7wdKWVDH0SPLC060CoZNeErXGaQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCnaTTbRL72V/6nGwXpRljTPnLtMl8DMna4vqtu+QwiygIhANEi42VbKUr8B0q/tGW8S99JRPkT/54zjrW+72R8EdJi"}],"size":4147,"noattachment":false,"key":"/node-macaddress/-/node-macaddress-0.1.1.tgz"},"deprecated":"'node-macaddress' was renamed to just 'macaddress', please use that one.","directories":{},"publish_time":1427742919464,"_cnpm_publish_time":1427742919464},"0.1.0":{"name":"node-macaddress","version":"0.1.0","description":"Get the MAC addresses (hardware addresses) of the hosts network interfaces.","main":"index.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"repository":{"type":"git","url":"https://github.com/scravy/node-macaddress.git"},"keywords":["mac","mac-address","hardware-address","network","system"],"author":{"name":"Julian Fleischer"},"license":"MIT","bugs":{"url":"https://github.com/scravy/node-macaddress/issues"},"homepage":"https://github.com/scravy/node-macaddress","dependencies":{"async":"^0.9.0"},"devDependencies":{"gulp":"^3.8.11","gulp-jshint":"^1.9.4"},"gitHead":"f6009714731723376abe099d713c2ff41fe75443","_id":"node-macaddress@0.1.0","_shasum":"624ef2ce092ade17409f00e1e3c7cf2bab73e00e","_from":".","_npmVersion":"2.1.10","_nodeVersion":"0.10.26","_npmUser":{"name":"scravy","email":"julian@scravy.de"},"maintainers":[{"name":"scravy","email":"julian@scravy.de"}],"dist":{"shasum":"624ef2ce092ade17409f00e1e3c7cf2bab73e00e","tarball":"http://registry-npm.ywwl.com/node-macaddress/download/node-macaddress-0.1.0.tgz","integrity":"sha512-m+aOq4DJXCXLp1Slkh2nSCAT5a771IGk5PNvdYrpByXU4+uuMAAM054smqCZmh1Hz5qXccedTbTewhhYLZ3iOQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDjKZzSyJ9GnEv9WmN5EaJaEPIz6mCtq1Og9RbV3+okoAIgBAz7p5639QPkYRGsWzKQ32stQykciojY30hh+PPpY/U="}],"size":3932,"noattachment":false,"key":"/node-macaddress/-/node-macaddress-0.1.0.tgz"},"deprecated":"'node-macaddress' was renamed to just 'macaddress', please use that one.","directories":{},"publish_time":1427740538113,"_cnpm_publish_time":1427740538113}},"readme":"node-macaddress\n===============\n\n[![Build Status](https://travis-ci.org/scravy/node-macaddress.svg?branch=master)](https://travis-ci.org/scravy/node-macaddress)\n\nRetrieve MAC addresses in Linux, OS X, and Windows.\n\nA common misconception about MAC addresses is that every *host* had *one* MAC address,\nwhile a host may have *multiple* MAC addresses – since *every network interface* may\nhave its own MAC address.\n\nThis library allows to discover the MAC address per network interface and chooses\nan appropriate interface if all you're interested in is *one* MAC address identifying\nthe host system (see `API + Examples` below).\n\n**Features:**\n\n+ works on `Linux`, `Mac OS X`, `Windows`, and on most `UNIX` systems.\n+ `node ≥ 0.12` and `io.js` report MAC addresses in `os.networkInterfaces()`\n  this library utilizes this information when available.\n+ also features a sane replacement for `os.networkInterfaces()`\n  (see `API + Examples` below).\n\nUsage\n-----\n\n```\nnpm install --save node-macaddress\n```\n\n```JavaScript\nvar macaddress = require('node-macaddress');\n```\n\nAPI + Examples\n--------------\n\n    (async)  .one(iface, callback) → string\n    (async)  .one(callback)        → string\n    (async)  .all(callback)        → { iface: { type: address } }\n    (sync)   .networkInterfaces()  → { iface: { type: address } }\n\n---\n\n### `.one([iface], callback)`\n\nRetrieves the MAC address of the given `iface`.\n\nIf `iface` is omitted, this function automatically chooses an\nappropriate device (e.g. `eth0` in Linux, `en0` in OS X, etc.).\n\n**Without `iface` parameter:**\n\n```JavaScript\nmacaddress.one(function (err, mac) {\n  console.log(\"Mac address for this host: %s\", mac);  \n});\n```\n\n```\n→ Mac address for this host: ab:42:de:13:ef:37\n```\n\n**With `iface` parameter:**\n\n```JavaScript\nmacaddress.one('awdl0', function (err, mac) {\n  console.log(\"Mac address for awdl0: %s\", mac);  \n});\n```\n\n```\n→ Mac address for awdl0: ab:cd:ef:34:12:56\n```\n\n---\n\n### `.all(callback)`\n\nRetrieves the MAC addresses for all non-internal interfaces.\n\n```JavaScript\nmacaddress.all(function (err, all) {\n  console.log(JSON.stringify(all, null, 2));\n});\n```\n\n```JavaScript\n{\n  \"en0\": {\n    \"ipv6\": \"fe80::cae0:ebff:fe14:1da9\",\n    \"ipv4\": \"192.168.178.20\",\n    \"mac\": \"ab:42:de:13:ef:37\"\n  },\n  \"awdl0\": {\n    \"ipv6\": \"fe80::58b9:daff:fea9:23a9\",\n    \"mac\": \"ab:cd:ef:34:12:56\"\n  }\n}\n```\n\n---\n\n### `.networkInterfaces()`\n\nA useful replacement of `os.networkInterfaces()`. Reports only non-internal interfaces.\n\n```JavaScript\nconsole.log(JSON.stringify(macaddress.networkInterfaces(), null, 2));\n```\n\n```JavaScript\n{\n  \"en0\": {\n    \"ipv6\": \"fe80::cae0:ebff:fe14:1dab\",\n    \"ipv4\": \"192.168.178.22\"\n  },\n  \"awdl0\": {\n    \"ipv6\": \"fe80::58b9:daff:fea9:23a9\"\n  }\n}\n```\n\n","_attachments":{},"homepage":"https://github.com/scravy/node-macaddress","bugs":{"url":"https://github.com/scravy/node-macaddress/issues"},"license":"MIT"}