Add XFRM Interface creation logic
This change adds logic to create XFRM interfaces.
AddVirtualTunnelInterface and RemoveVirtualTunnelInterface also have
been renamed to the more standard ipSec* naming scheme, as well as
returning a Status instead of integers as part of extracting common
code.
This patch should change no functionality.
This is part of a patch set to enable XFRM-I support, with automatic
fallbacks to VTI in XfrmController (1/3)
Bug: 77856928
Test: Binder, unit tests passing on devices with, and without XFRM-I
Change-Id: I403b01f7817715117faa270277db67ba40bbf6dd
diff --git a/server/NetdNativeService.h b/server/NetdNativeService.h
index 62f9b3f..dcac193 100644
--- a/server/NetdNativeService.h
+++ b/server/NetdNativeService.h
@@ -222,21 +222,17 @@
binder::Status trafficCheckBpfStatsEnable(bool* ret) override;
- binder::Status addVirtualTunnelInterface(
- const std::string& deviceName,
- const std::string& localAddress,
- const std::string& remoteAddress,
- int32_t iKey,
- int32_t oKey);
+ binder::Status ipSecAddTunnelInterface(const std::string& deviceName,
+ const std::string& localAddress,
+ const std::string& remoteAddress, int32_t iKey,
+ int32_t oKey);
- binder::Status updateVirtualTunnelInterface(
- const std::string& deviceName,
- const std::string& localAddress,
- const std::string& remoteAddress,
- int32_t iKey,
- int32_t oKey);
+ binder::Status ipSecUpdateTunnelInterface(const std::string& deviceName,
+ const std::string& localAddress,
+ const std::string& remoteAddress, int32_t iKey,
+ int32_t oKey);
- binder::Status removeVirtualTunnelInterface(const std::string& deviceName);
+ binder::Status ipSecRemoveTunnelInterface(const std::string& deviceName);
// Idletimer-related commands
binder::Status idletimerAddInterface(const std::string& ifName, int32_t timeout,