Categorygithub.com/soypat/netif
modulepackage
0.0.0-20240430184307-e7dfef0020a6
Repository: https://github.com/soypat/netif.git
Documentation: pkg.go.dev

# README

netif

go.dev reference Go Report Card codecov Go stability-frozen sourcegraph License: MIT

Networking interfaces. For now I'm adding a TAP interface I can understand

Debugging with VSCode

To run with an ethernet interface you'll need to open VSCode as sudo with --no-sandbox option:

sudo code --user-data-dir ~/.config/Code --no-sandbox .

You may need to install the Go extension and Delve as sudo since you are opening VSCode as a different user.

Creating a launch.json maps directly to using VSCode normally. Here's an example:

{
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Launch Package",
            "type": "go",
            "request": "launch",
            "mode": "auto",
            "program": "${workspaceFolder}/examples/mqtt/",
        }
    ]
}

# Packages

No description provided by the author
No description provided by the author

# Functions

Default interface returns the default network interface over which traffic is routed.
NewEngine returns a networking engine that uses the given network interface controller.
No description provided by the author
OpenTap opens an existing TAP device by name.

# Constants

No description provided by the author
No description provided by the author
The device's network connection is now DOWN.
The device's network connection is now UP.

# Structs

No description provided by the author
No description provided by the author
No description provided by the author
Tap implements Unix TAP interface.

# Interfaces

Interface is the minimum interface that need be implemented by any network device driver and is based on [net.Interface].
InterfaceEthPoller is implemented by devices that send/receive ethernet packets.
Resolver is the interface for DNS resolution, as implemented by the `net` package.

# Type aliases

No description provided by the author
No description provided by the author