Get-MacAddress.ps1

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47

<#PSScriptInfo
 
.VERSION 1.2.1
 
.GUID 50883596-755d-4273-a5f6-b65f1cde67a4
 
.AUTHOR Benakor
 
.COMPANYNAME
 
.COPYRIGHT Benaiah Youquoi
 
.TAGS MACaddress Mac
 
.LICENSEURI
 
.PROJECTURI
 
.ICONURI
 
.EXTERNALMODULEDEPENDENCIES
 
.REQUIREDSCRIPTS
 
.EXTERNALSCRIPTDEPENDENCIES
 
.RELEASENOTES
The AdapterType has been added to identify the network adapter type Ex. 802.11n.
 
#>
 





<#
 
.DESCRIPTION
 Retrieves MAC addresses of remote or local machines and shows networkcard maximum speed.
 
#>
 
Param ([string[]] $computername = 'localhost')
gwmi win32_NetworkAdapter -ComputerName $computername | Select Name, MacAddress, @{l='Max Speed (Mb) '; e={$_.Speed / 1000000 -as [int]}}, AdapterType