// // Created by xajhuang on 2023/3/23. // #ifndef VCPE_IP_POOL_H #define VCPE_IP_POOL_H #include #include #include #ifdef __cplusplus extern "C" { #endif typedef struct POOL_CTX { U32 minAddr; U32 maxAddr; U32 netMask; U32 gwAddr; U32 primeDNS; U32 salveDNS; U32 leaseTime; struct POOL_CTX *next, *prev; } POOL_CTX, *PPOOL_CTX; typedef struct { U32 id; ///< ID PPOOL_CTX pCtx; ///< 用户配置信息 UT_hash_handle hh; } POOL_CONFIG, *PPOOL_CONFIG; void ip_pool_init_from_config(); PPOOL_CTX get_pool_cfg(U32 uid, U32 gid); #ifdef __cplusplus } #endif #endif //VCPE_IP_POOL_H