Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

v2ray self-signed certificate error #36

Closed
jose-C2OaWi opened this issue Aug 25, 2022 · 1 comment
Closed

v2ray self-signed certificate error #36

jose-C2OaWi opened this issue Aug 25, 2022 · 1 comment
Labels
bug Something isn't working

Comments

@jose-C2OaWi
Copy link

I choose vless+tcp+tls and use self-signed certificate. In nekoray in security settings I copy the plain text of my certificate into the certificate entry and get this error:

infra/conf/serial: failed to read config file at line 1 char 12 > json: cannot unmarshal string into Go struct field TLSCertConfig.outbounds.streamSettings.tlsSettings.certificates.certificate of type []string

I also try typing into the path of my certificate file, but got the same error.

Here is the relevant log:
"outbounds":[{"domainStrategy":"AsIs","protocol":"vless","settings":{"vnext":[{"address":"you don't need to know","port":443,"users":[{"encryption":"none","id":"aaa"}]}]},"streamSettings":{"network":"tcp","security":"tls","tlsSettings":{"alpn":["h2"," http/1.1"," h3"],"certificates":[{"certificate":"-----BEGIN CERTIFICATE-----\n11111111aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\n222222aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\n333333aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\n44444aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\n-----END CERTIFICATE-----"}],"serverName":"gov.cn"}},"tag":"g-230045"},

My nekoray version is nekoray-1.4-2022-08-22, V2Ray version is 5.0.8.
According to v2fly document, the value of "certificate" should be an array of string but nekoray puts in a string.
My configuration works fine with V2Ray 4.45.2 if I specify the certificatFile in tls settings.

@arm64v8a arm64v8a added the bug Something isn't working label Aug 25, 2022
arm64v8a added a commit that referenced this issue Aug 25, 2022
@arm64v8a
Copy link
Contributor

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants