Skip to content

对原项目新增了一些功能,golang版http.server,可在内网环境快速搭建http服务,上传OR下载

License

Notifications You must be signed in to change notification settings

nu0l/HTTPUploadExfil

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

原版README

地址: README.md

新增

[+] 自定义端口号

[+] 自定义路径

[+] 新增token鉴权

使用

直接运行, 端口号默认为58080, 路径目录默认为./data, token默认为空

httpuploadexfil.exe -h
Usage of httpuploadexfil.exe:
  -listen string
        Listening address (e.g., :58080) (default ":58080")
  -storage string
        Folder to store uploaded files (default "./data")
  -token string
        Access token (optional; if empty, no token check)

接口说明文档

接口路径 请求方法 描述 请求参数
/upload-form GET 返回上传文件的HTML表单页面
/upload POST 上传文件 表单字段 file,包含上传文件内容
/log-request GET 保存当前请求完整信息到日志文件
/files/* GET 访问存储目录下的文件 路径参数,访问 /files/xxx 映射到存储目录

Token使用说明

如果启动时带了 -token=xxx 参数,所有接口都会校验请求头中 token 字段是否匹配,否则拒绝访问。

token: xxx

如果未设置token,则接口不做权限验证,所有请求均可访问。

上传文件说明

上传的文件会根据当前日期自动分类存放到存储目录的子目录中,目录格式为 YYYY-MM-DD。

日志保存说明

/log-request接口将客户端请求按时间和IP保存成文本文件,便于后续审计。

About

对原项目新增了一些功能,golang版http.server,可在内网环境快速搭建http服务,上传OR下载

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 94.4%
  • Makefile 5.6%