在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):hamishforbes/lua-resty-iputils开源软件地址(OpenSource Url):https://github.com/hamishforbes/lua-resty-iputils开源编程语言(OpenSource Language):Perl 74.6%开源软件介绍(OpenSource Introduction):lua-resty-iputilsCollection of utility functions for working with IP addresses. Overview
Methodsenable_lrucache
Creates a global lrucache object for caching ip2bin lookups. Size is optional and defaults to 4000 entries (~1MB per worker) Calling this repeatedly will reset the cache ip2bin
Returns the binary representation of an IPv4 address and a table containing the binary representation of each octet Returns parse_cidr
Returns a binary representation of the lowest (network) and highest (broadcast) addresses of an IPv4 network. parse_cidrs
Takes a table of CIDR format IPV4 networks and returns a table of tables containg the lower and upper addresses. If an invalid network is in the table an error is logged and the other networks are returned ip_in_cidrs
Takes a string IPv4 address and a table of parsed CIDRs (e.g. from Returns a Returns binip_in_cidrs
Takes a nginx binary IPv4 address (e.g. This method is much faster than Returns a Returns TODO
|
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论