dteam-top / dgate Goto Github PK
View Code? Open in Web Editor NEWan API Gateway based on Vert.x
License: Apache License 2.0
an API Gateway based on Vert.x
License: Apache License 2.0
dgate/src/main/java/top/dteam/dgate/utils/JWTTokenGenerator.java:19: error: incompatible types: Long cannot be converted to int
改为:
options.setExpiresInSeconds(expiration.intValue());
就可以了。
经过dgate的请求到了后端看到的始终是dgate发过来的请求。为了能让后端得到真正的用户请求,便于真正的后端对客户端进行某些统计,计划仿照反向代理的通用做法,添加这三个HTTP Header,告知后端真正的用户ip。
同时,添加User-Agent
头,以便于后台统计用户浏览器
目前断路器的日志属于INFO
级别,并且输出过于频繁,会产生大量的日志,十分吵,并且极容易冲掉有用的日志信息。
考虑优化断路器的日志输出,仅仅在断路器状态变化时打印INFO
级别日志,原本的输出信息考虑放在DEBUG
级别。
正常情况,一个接口会有多种返回,比如正常和异常返回。有时正常返回,不同的参数返回结果也有差别
调试时每次修改接口返回内容比较麻烦,
建议可以配置多种返回,可指定返回哪种
这样在调试时就可以模拟多种情况了。
mock也可以直接作为接口文档使用了。
如题
如题
目前登录验证单单是通过判断token是否过期进行的, 便会存在如下场景:
攻击者解析token获取token组成规则(token中的key->id为用户id), 修改token中的id, 重新生成未过期的token, 利用新的token, 便可模拟任何用户操作, 从而进行攻击.
现在能否规避此问题?
流量达到上限后,新的请求直接拒绝,并返回定制的消息,
目前版本暂无对文件上传和下载的支持,不知是否考虑了相关功能,甚是期待。
如果后台url使用的rest api,相同的url需要通过method区分不同的操作
Exception in thread "main" java.lang.NoClassDefFoundError: sun/misc/SharedSecrets
此功能可以防止爬虫通过固定的URL爬取到后端服务返回的数据。
配置url无需验证登录(即login->only不包含相应链接), 当用户已登陆, 无法获取相应token信息
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.