Skip to content

【功能建议】认证信息可以参数形式传递 #467

Closed

Description

@soffchen

目前认证信息是 user:pass@host:port,对于一些特殊字符的不能直接使用,比如用户名是邮箱,包含 @ 的话就不行。虽然有提供 secret.txt 来实现,但是就不能通过一条命令就完整实现一个完成转发功能。

是否可以考虑增加这样方式 schema://host:port?user=xxxxx&pass=xxxx,比如 socks5://1.2.3.4:1080?user=a@b.com&password=xxxxxx,甚至可以先对参数做一次urldecode

Activity

  1. ginuerzh commented on Jan 11, 2020

    @ginuerzh
    Owner

    可以考虑加参数

  2. endokai commented on Jan 16, 2020

    @endokai

    只是换到参数里面这样密码如果有&就又不能用了,这实际需要的应该是一个转义功能,比如使用\来对后续的一个字符进行转义。

  3. soffchen commented on Jan 16, 2020

    @soffchen
    ContributorAuthor

    原来的形式还兼容,有 & 放前面好了,上面也提到参数可以提供 urlencode 的方案。%4012125%2612

  4. endokai commented on Jan 16, 2020

    @endokai

    有&放前面,有@放后面?明显多余了,而且要是两个同时有怎么办。而转义的话既通用又操作简单,也是易读易编写的,编码还需要第三方工具,还不如写文件。而且你密码本身是字面的%40怎么办?是不是还要继续想怎么解决这个问题,比如用另外的参数区别是urlencode还是字面的密码

  5. endokai commented on Jan 16, 2020

    @endokai

    除非是使用参数的形式强制使用url编码,就如一般的浏览器网址一样。不过就如我说的显得有些多余和麻烦。虽然gost的参数是类URL的,但运行还是在命令行里面运行的,感觉不必太刻意模仿

  6. ginuerzh commented on Jan 16, 2020

    @ginuerzh
    Owner

    可以采用http的basic auth方式,进行base64编码,这样就不用考虑这么多问题了。

  7. changchichung commented on Jan 21, 2020

    @changchichung

    請問能加入 sha512 hash 的密碼支援嗎?

  8. ginuerzh commented on Jan 22, 2020

    @ginuerzh
    Owner

    @changchichung 具体用处?

  9. added a commit that references this issue on Jan 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      ⌂ 换网址