summaryrefslogtreecommitdiffhomepage
path: root/pkg/tcpip/stack/registration.go
diff options
context:
space:
mode:
authorGoogler <noreply@google.com>2019-02-26 14:57:27 -0800
committerShentubot <shentubot@google.com>2019-02-26 14:58:37 -0800
commit12d9cf6fabb53d18da3602564f45ff6fbbf032d6 (patch)
tree176227d1ca05a54c89d1236e58dc2793b8b74abb /pkg/tcpip/stack/registration.go
parenta2b794b30dd952793f4d99a9423cef7efdc7843f (diff)
Adds a WriteRawPacket method to the InjectableLinkEndpoint interface.
Also exposes ipv4.MaxTotalSize since it is a generally useful constant. PiperOrigin-RevId: 235799755 Change-Id: I1fa8d5294bf355acf5527cfdf274b3687d3c8b13
Diffstat (limited to 'pkg/tcpip/stack/registration.go')
-rw-r--r--pkg/tcpip/stack/registration.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/pkg/tcpip/stack/registration.go b/pkg/tcpip/stack/registration.go
index 010d51886..5accffa1b 100644
--- a/pkg/tcpip/stack/registration.go
+++ b/pkg/tcpip/stack/registration.go
@@ -260,6 +260,11 @@ type InjectableLinkEndpoint interface {
// Inject injects an inbound packet.
Inject(protocol tcpip.NetworkProtocolNumber, vv buffer.VectorisedView)
+
+ // WriteRawPacket writes a fully formed outbound packet directly to the link.
+ //
+ // dest is used by endpoints with multiple raw destinations.
+ WriteRawPacket(dest tcpip.Address, packet []byte) *tcpip.Error
}
// A LinkAddressResolver is an extension to a NetworkProtocol that