negroni-iprestrict:Iprestrict negroni中间件可限制对特定IP地址的访问

时间:2024-06-10 05:29:15
【文件属性】:

文件名称:negroni-iprestrict:Iprestrict negroni中间件可限制对特定IP地址的访问

文件大小:3KB

文件格式:ZIP

更新时间:2024-06-10 05:29:15

Go

Iprestrict Negroni中间件 Iprestrict中间件以限制对特定IP地址的访问 用法 package main import ( "fmt" "github.com/codegangsta/negroni" "github.com/rabeesh/negroni-iprestrict" "net/http" ) func main () { mux := http . NewServeMux () mux . HandleFunc ( "/" , func ( rw http. ResponseWriter , req * http. Request ) { fmt . Fprintf ( rw , "Welcome to the home page!" ) }) rips := [] st


【文件预览】:
negroni-iprestrict-master
----iprestrict.go(732B)
----readme.md(658B)
----iprestrict_test.go(1KB)
----LICENSE(1KB)

网友评论