yzqzss|一座桥在水上's Note
399 subscribers
243 photos
18 videos
4 files
225 links
除有转发标记或特别说明的,均以 CC0 协议共享。

我是一个垃圾人,所以我经常干些垃圾事儿。
本人符合 GB50917-2013 之要求。

我不卖菜,我是真的菜鸡,不爱学习。
毫无疑问,我没上进心,我是普通人。
存档是我的爱好。
Download Telegram
This media is not supported in your browser
VIEW IN TELEGRAM
最烦解决 stash pop 的冲突了。
😁1
翻墙能力资格测验,今日起正式开赛。
🤔7
如果是 AI 爬虫导致的话,这算公地悲剧吗?
买全新服务器,预算2w~4w,走报销。要求国内品牌。
懂行的可以推荐些型号吗?

要是我自己买肯定就是捡垃圾了,但是是学校买,说二手不好走账,非得国产+全新。
看了眼,全新的价格都很坑爹。

用于虚拟化开小鸡。
🤩2
今天看了啥:

https://html.spec.whatwg.org/multipage/urls-and-fetching.html#resolving-urls

Let encoding be UTF-8.
If environment is a Document object, then set [encoding] (document charset) to environment's character encoding.


https://url.spec.whatwg.org/#query-state

2. Percent-encode after encoding, with [encoding], buffer, and queryPercentEncodeSet, and append the result to url’s query.


https://url.spec.whatwg.org/#path-state

1. ...special cases...
2. Otherwise, run these steps:
.... special cases ...
3. UTF-8 percent-encode c using the path percent-encode set and append the result to buffer.



好 TM 抽象啊,web 就是一坨屎山。
😐3
This media is not supported in your browser
VIEW IN TELEGRAM
🥰4
前天、昨天、今天看了啥:

网文。😂
🥰1
yzqzss|一座桥在水上's Note
TG 小功能:时光机 全局搜索栏中输入日期,可以全局搜索指定日期范围内的多个聊天会话中的消息。 *无法绕过群聊聊天记录 100 万回溯限制。
TG 小功能:魔术搜索词

搜索 @ 可显示所有别人 @ 了你或者回复了你的消息的消息。
搜索 + 可显示所有消息。

@Ovler 发现。
小挑战:接下来30天写代码不用 AI
🤯52
Forwarded from 囍频道 (IceCode New)
https://github.com/IceCodeNew/anata-no-minato

在那之后 @yzqzss 开发了一个 Python 脚本用于自动从 ~/.ssh/config 转换出 hosts.csv 配置
我非常欣赏这个脚本,征求过同意以后把这段脚本集成到了我的项目里。感谢他给我的启发(和借我抄的作业)
现在你可以在 https://github.com/IceCodeNew/anata-no-minato 上看到我新开的 bug 全家桶啦~

新的镜像只需要挂载 ${HOME}/.ssh/ 目录就可以食用了。但是仍然推荐参考 README.md 下方的说明,生成 ananta 函数并写入 ~/.bashrc 文件,这样日后使用只要简单执行 ananta whoami 即可
🤩3
笑死了,碰到一个 ctf 系统:

- 把选择题答案明晃晃放前端 html 里。
- 一个队里的不同用户可分别提交同一个题,共同计分。
- API 没有用户鉴权,提交只需要 user_id 和 team_id 。可当全员好人,帮别人提交。

相关域名: bestctf.com
🤣2
Forwarded from 
哇,现在还有什么场合要用到电报
yzqzss|一座桥在水上's Note
今天看了啥: https://html.spec.whatwg.org/multipage/urls-and-fetching.html#resolving-urls Let encoding be UTF-8. If environment is a Document object, then set [encoding] (document charset) to environment's character encoding. https://url.spec.whatwg.org/#query…
又是被 URL 创的一天:我还在被 url 折磨……

1.
空格的 escape 规则是脑溢血, path 部分必须用 %20,path 中的 + 就表示加号本身;query 部分可以用 %20 或 + ,加号本身反而需要转义。(为什么呢?因为历史遗留问题,我甚至也没找到 + 的标准在哪儿定义的,RFC 3986 里真没写 + 可以用于转义空格)
https://stackoverflow.com/questions/1634271/url-encoding-the-space-character-or-20
(for backwards compatibility: do not try to search for it in the URI standard)


现代浏览器使用 %20。但是各种语言的库出于兼容性仍然使用 + 来 escape 空格。

但是但是,在非 web 的世界里,大家又遵守标准的 URI 规范了……如 mailto 中:

Note that for email links, you do need %20 and not + after the ?. For example, mailto:support@example.org?subject=I%20need%20help. If you tried that with +, the email will open with +es instead of spaces.


2.
由于 / 可被 escape 成 %2F ,而 url path resolve 标准化 (处理 path 中的 ../ 和 ./) 过程只对 / 字面量生效 (resolve 发生在 url unescape 之前)
而经过 unescape 后,%2F 和真正的 / 都被 unescape 成了 /,这时候 url 的 path 就不是它真正的 path 了。

所以需要保留原始的 path 用于正确处理 url join ,而不是用解码后的 path。

我感觉这里会有好玩的事情发生。
如果一些 http web 框架/反向代理/WAF/CDN 的机制不一致,比如一个是用 resolve+unescape 后的 path 来路由,一个使用 resolve 了但没有 unescape 的 path 来路由,一个使用原始的 path 来路由。
嘿嘿嘿/

3.
url path 中如果出现非有效 hex 的百分号编码(比如 %ZZ),基本上各种 http server 会无条件拒绝,返回 400 ,有些则是直接断连接。
但是,如果 query 中出现了非有效的 hex,大家的选择是丢掉坏掉的那一项 query kv pair。