Jadpo
Jadpo是一种实验性的web后端编程语言 编码代理编写代码,一个人审核代码。数据、HTTP路由、登录、 控件中声明了权限、外部服务和后台工作 语言,以便编译器可以一起检查它们并回答审查 问题:这个应用程序能做什么,谁能做,它能到达什么地方?
编译器捕获什么
你要求你的代理向合作伙伴展示他们的详细信息,然后它会发回他们的 API密钥。在Jadpo中无法编译:
type PartnerName = Text {
max_length: 100
}
/// What the partners page shows of a partner.
type PartnerProfile = Output {
name: PartnerName
partner_key: ApiKey
}
error: `PartnerProfile.partner_key` holds an `ApiKey`
--> main.jadpo:8:18
|
8 | partner_key: ApiKey
| ^^^^^^ sent to a client
reason: An `ApiKey` is a secret value: it is never sent, logged, stored or shown. A response is written out, logged by proxies and kept by browsers, and a client never needs a secret back.
next: Remove `partner_key`, and send what the client needs instead, such as whether one is set (agent)
rule: type.secret_exposed
help: https://jadpo.dev/docs/errors/type.secret_exposed
check failed: 1 error, 1 file
这是编译器的实际输出,在每次更改时进行检查。它命名了
修复和谁应该做它: (agent) 意味着你的编码代理可以修复它
本身。泄漏字段,跳过登录的路由,获取的记录
不检查谁可以看到它:每一个都是像这样的编译错误。
了解更多
状态
实验。指定了该语言的所有21个区域。编译器 在解释器中运行程序并构建本机和WebAssembly 可部署,但尚未构建指定的所有内容。生产 针对已建立的堆栈的准备和性能尚未建立。 这个 路线图 剩下的是什么,还有 jadpo.dev /状态 展示了今天的建筑。
从源代码构建
你需要Git和Rust rustup;存储库固定工具链。
git clone https://github.com/jadpo-dev/jadpo.git && cd jadpo
cargo build --release --locked -p jadpo-cli
target/release/jadpo test examples/01-first-project
这个 28个教学项目 从第一个函数到 数据库、身份验证、集成和人工智能。
贡献,报告,许可
- CONTRIBUTING.md:设置,验证门和工作规则。
- SECURITY.md:如何报告漏洞。
- 问题 对于bug和问题。
代码是 Apache 2.0;文档是 Cc 4.0. 看到 TRADEMARKS.md 使用Jadpo的名字。