Skip to content

Commit c84e795

Browse files
committed
Merge branch 'master' of github.com:/v2fly/v2ray-core
2 parents 82ae56e + a1e4c9b commit c84e795

File tree

11 files changed

+18
-109
lines changed

11 files changed

+18
-109
lines changed

app/dispatcher/default.go

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -288,9 +288,10 @@ func (d *DefaultDispatcher) routedDispatch(ctx context.Context, link *transport.
288288
return
289289
}
290290

291-
accessMessage := log.AccessMessageFromContext(ctx)
292-
if accessMessage != nil {
293-
accessMessage.Detour = "[" + handler.Tag() + "]"
291+
if accessMessage := log.AccessMessageFromContext(ctx); accessMessage != nil {
292+
if tag := handler.Tag(); tag != "" {
293+
accessMessage.Detour = tag
294+
}
294295
log.Record(accessMessage)
295296
}
296297

azure-pipelines.template.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
- checkout: self
1010
- task: GoTool@0
1111
inputs:
12-
version: '1.14'
12+
version: '1.13'
1313
- script: |
1414
go test -p 1 -v -timeout 30m ./...
1515
workingDirectory: '$(Build.SourcesDirectory)'

common/buf/io.go

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -65,12 +65,7 @@ func NewReader(reader io.Reader) Reader {
6565
if err != nil {
6666
newError("failed to get sysconn").Base(err).WriteToLog()
6767
} else {
68-
/* Check if ReadVReader Can be used on this reader first
69-
Fix https://github.com/v2ray/v2ray-core/issues/1666
70-
*/
71-
if ok, _ := checkReadVConstraint(rawConn); ok {
72-
return NewReadVReader(reader, rawConn)
73-
}
68+
return NewReadVReader(reader, rawConn)
7469
}
7570
}
7671
}

common/buf/readv_constraint_other.go

Lines changed: 0 additions & 9 deletions
This file was deleted.

common/buf/readv_constraint_windows.go

Lines changed: 0 additions & 41 deletions
This file was deleted.

common/log/access.go

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ type AccessMessage struct {
2525
To interface{}
2626
Status AccessStatus
2727
Reason interface{}
28-
Detour interface{}
28+
Email string
29+
Detour string
2930
}
3031

3132
func (m *AccessMessage) String() string {
@@ -36,8 +37,11 @@ func (m *AccessMessage) String() string {
3637
builder.WriteByte(' ')
3738
builder.WriteString(serial.ToString(m.To))
3839
builder.WriteByte(' ')
39-
builder.WriteString(serial.ToString(m.Detour))
40-
builder.WriteByte(' ')
40+
if len(m.Detour) > 0 {
41+
builder.WriteByte('[')
42+
builder.WriteString(m.Detour)
43+
builder.WriteString("] ")
44+
}
4145
builder.WriteString(serial.ToString(m.Reason))
4246

4347
if len(m.Email) > 0 {

infra/conf/command/command.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ package command
33
//go:generate errorgen
44

55
import (
6-
"bufio"
76
"os"
87

98
"github.com/golang/protobuf/proto"
@@ -28,7 +27,7 @@ func (c *ConfigCommand) Description() control.Description {
2827
}
2928

3029
func (c *ConfigCommand) Execute(args []string) error {
31-
pbConfig, err := serial.LoadJSONConfig(bufio.NewReader(os.Stdin))
30+
pbConfig, err := serial.LoadJSONConfig(os.Stdin)
3231
if err != nil {
3332
return newError("failed to parse json config").Base(err)
3433
}

release/install-release.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -447,7 +447,7 @@ main(){
447447
RETVAL="$?"
448448
if [[ $RETVAL == 0 ]] && [[ "$FORCE" != "1" ]]; then
449449
colorEcho ${BLUE} "Latest version ${CUR_VER} is already installed."
450-
if [[ "${ERROR_IF_UPTODATE}" == "1" ]]; then
450+
if [ -n "${ERROR_IF_UPTODATE}" ]; then
451451
return 10
452452
fi
453453
return

release/user-package.sh

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -86,14 +86,6 @@ packtgzAbPath() {
8686
echo ">>> Generated: $ABPATH"
8787
}
8888

89-
packtgzAbPath() {
90-
local ABPATH="$1"
91-
echo ">>> Generating tgz package at $ABPATH"
92-
pushd $TMP
93-
tar cvfz $ABPATH .
94-
echo ">>> Generated: $ABPATH"
95-
}
96-
9789

9890
pkg=zip
9991
nosource=0
@@ -169,7 +161,7 @@ if [[ $pkg == "zip" ]]; then
169161
elif [[ $pkg == "tgz" ]]; then
170162
packtgz
171163
else
172-
packtgzAbPath $pkg
164+
packtgzAbPath "$pkg"
173165
fi
174166

175167

transport/internet/tls/config.go

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -187,24 +187,8 @@ func (c *Config) GetTLSConfig(opts ...Option) *tls.Config {
187187
}
188188

189189
if !c.AllowInsecureCiphers && len(config.CipherSuites) == 0 {
190-
config.CipherSuites = []uint16{
191-
tls.TLS_AES_128_GCM_SHA256,
192-
tls.TLS_AES_256_GCM_SHA384,
193-
tls.TLS_CHACHA20_POLY1305_SHA256,
194-
195-
tls.TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305,
196-
tls.TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305,
197-
tls.TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,
198-
tls.TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,
199-
tls.TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,
200-
tls.TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,
201-
tls.TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,
202-
tls.TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA,
203-
tls.TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,
204-
tls.TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA,
205-
tls.TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA,
206-
tls.TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA,
207-
}
190+
// crypto/tls will use the proper ciphers
191+
config.CipherSuites = nil
208192
}
209193

210194
config.InsecureSkipVerify = c.AllowInsecure

0 commit comments

Comments
 (0)