Skip to content

Instantly share code, notes, and snippets.

View pmgexpo17's full-sized avatar

Peter McGill pmgexpo17

  • Brisbane, Queensland Australia
View GitHub Profile
@Ultraporing
Ultraporing / main.go
Last active April 26, 2024 01:41
Golang implementation of an physical network interface filter usefull for packetsniffing and pcap. It provides you with the Adapter Name (in windows Friendly Name in addition) and MAC Address. Tunnels (VMs and such), loopback adapters get ignored. I updated my code from the https://github.com/regner/albiondata-client project and added an example.
package main
import (
"fmt"
ifil "./ifilter"
)
func main() {
physicalInterfaceList := ifil.GetAllPhysicalInterfaces()
fmt.Println("All Physical Network Interfaces:", physicalInterfaceList)
@danesparza
danesparza / exec.go
Last active June 28, 2023 20:41
Go exec.Command example
package main
import (
"bytes"
"fmt"
"os/exec"
"strings"
)
func main() {