[GH-ISSUE #3839] Bug report #2595

Closed
opened 2026-10-31 20:26:35 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @MrDexstor on GitHub (Feb 22, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/3839

Describe the bug

`2026/02/22 13:54:43 WARNING - XRAY: core: Xray 26.2.6 started
2026/02/22 13:54:51 DEBUG - Core crash detected:
panic: runtime error: slice bounds out of range [566:536]

goroutine 2049 [running]:
github.com/xtls/xray-core/common/buf.(*Buffer).Extend(...)
github.com/xtls/xray-core/common/buf/buffer.go:153
github.com/xtls/xray-core/proxy.XtlsPadding(0xc000fe6c90, 0x0, 0xc002c1f2d8, 0x80?
2026/02/22 13:54:51 DEBUG - XRAY: , {0x1a7d1e0, 0xc000af9e90}, {0xc00098cc70?, 0x4?, 0x1?})
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/proxy.go:519 +0x79e
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy.(*VisionWriter).WriteMultiBuffer(0xc002c1f290, {0xc001d01658, 0x1, 0x1})
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/proxy.go:390 +0x5dd
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/app/dispatcher.(*SizeStatWriter).WriteMultiBuffer(0xc001f5f140, {0xc001d01658, 0x1, 0x1})
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/app/dispatcher/stats.go:16 +0x68
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/encoding.XtlsRead.func1(...)
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/encoding/encoding.go:191
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/encoding.XtlsRead({0x1a6ac20, 0xc000c3a150}, {0x1a693c0, 0xc001f5f140}, 0xc0007c0a80, {0x1a85838, 0xc000fe6450}, 0xc000865f10, 0x0, {0x1a7d1a8, ...})
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/encoding/encoding.go:199 +0x143
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/outbound.(*Handler).Process.func5()
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/outbound/outbound.go:391 +0x8a5
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/outbound.(*Handler).Process.OnSuccess.func10()
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/common/task/task.go:12 +0x22
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/common/task.Run.func1(0xc00050d1e0?)
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/common/task/task.go:28 +0x28
2026/02/22 13:54:51 DEBUG - XRAY: created by github.com/xtls/xray-core/common/task.Run in goroutine 1928
2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/common/task/task.go:27 +0xdb
2026/02/22 13:54:51 ERROR - Failure in running xray-core: exit status 2
2026/02/22 13:54:53 DEBUG - restart Xray, force: false`

I get such logs at a random moment and xray crashes

How to repeat the problem?

Full random

Expected action

No

Received action

No response

3x-ui Version

26.2.6

Xray-core Version

26.2.6

Checklist

  • This bug report is written entirely in English.
  • This bug report is new and no one has reported it before me.
Originally created by @MrDexstor on GitHub (Feb 22, 2026). Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/3839 ### Describe the bug `2026/02/22 13:54:43 WARNING - XRAY: core: Xray 26.2.6 started 2026/02/22 13:54:51 DEBUG - Core crash detected: panic: runtime error: slice bounds out of range [566:536] goroutine 2049 [running]: github.com/xtls/xray-core/common/buf.(*Buffer).Extend(...) github.com/xtls/xray-core/common/buf/buffer.go:153 github.com/xtls/xray-core/proxy.XtlsPadding(0xc000fe6c90, 0x0, 0xc002c1f2d8, 0x80? 2026/02/22 13:54:51 DEBUG - XRAY: , {0x1a7d1e0, 0xc000af9e90}, {0xc00098cc70?, 0x4?, 0x1?}) 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/proxy.go:519 +0x79e 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy.(*VisionWriter).WriteMultiBuffer(0xc002c1f290, {0xc001d01658, 0x1, 0x1}) 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/proxy.go:390 +0x5dd 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/app/dispatcher.(*SizeStatWriter).WriteMultiBuffer(0xc001f5f140, {0xc001d01658, 0x1, 0x1}) 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/app/dispatcher/stats.go:16 +0x68 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/encoding.XtlsRead.func1(...) 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/encoding/encoding.go:191 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/encoding.XtlsRead({0x1a6ac20, 0xc000c3a150}, {0x1a693c0, 0xc001f5f140}, 0xc0007c0a80, {0x1a85838, 0xc000fe6450}, 0xc000865f10, 0x0, {0x1a7d1a8, ...}) 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/encoding/encoding.go:199 +0x143 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/outbound.(*Handler).Process.func5() 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/outbound/outbound.go:391 +0x8a5 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/proxy/vless/outbound.(*Handler).Process.OnSuccess.func10() 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/common/task/task.go:12 +0x22 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/common/task.Run.func1(0xc00050d1e0?) 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/common/task/task.go:28 +0x28 2026/02/22 13:54:51 DEBUG - XRAY: created by github.com/xtls/xray-core/common/task.Run in goroutine 1928 2026/02/22 13:54:51 DEBUG - XRAY: github.com/xtls/xray-core/common/task/task.go:27 +0xdb 2026/02/22 13:54:51 ERROR - Failure in running xray-core: exit status 2 2026/02/22 13:54:53 DEBUG - restart Xray, force: false` I get such logs at a random moment and xray crashes ### How to repeat the problem? Full random ### Expected action No ### Received action _No response_ ### 3x-ui Version 26.2.6 ### Xray-core Version 26.2.6 ### Checklist - [x] This bug report is written entirely in English. - [x] This bug report is new and no one has reported it before me.
bsakaguchi 2026-10-31 20:26:35 +07:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@gallyamb commented on GitHub (Feb 24, 2026):

The same for me. xray 26.2.6. 3xui 2.8.10

When there is no any connections to the xray, the core stays "stable". When connection is established it's crashed. Between crashes some data is proxied, though. But it crashes every 5-10 seconds

Stacktrace is identical, but providing it anyway

Stacktrace
Core crash detected: panic: runtime error: slice bounds out of range [540:179]
goroutine 698 [running]: 
github.com/xtls/xray-core/common/buf.(*Buffer).Extend(...) 
github.com/xtls/xray-core/common/buf/buffer.go:153 
github.com/xtls/xray-core/proxy.XtlsPadding(0xc000584fc0, 0x2, 0xc000572318, 0x17?, {0x1a7d1e0, 0xc0001abef0}, {0xc000295590?, 0x4?, 0xc00067ee01?}) 
github.com/xtls/xray-core/proxy/proxy.go:519 +0x79e 
github.com/xtls/xray-core/proxy.(*VisionWriter).WriteMultiBuffer(0xc0005722d0, {0xc000053500, 0x1, 0x1}) 
github.com/xtls/xray-core/proxy/proxy.go:374 +0x51f 
github.com/xtls/xray-core/app/dispatcher.(*SizeStatWriter).WriteMultiBuffer(0xc00056d6a0, {0xc000053500, 0x1, 0x1}) 
github.com/xtls/xray-core/app/dispatcher/stats.go:16 +0x68 
github.com/xtls/xray-core/proxy.CopyRawConnIfExist({0x1a7d1a8, 0xc000425d10}, {0x1a85940?, 0xc000053358?}, {0x1a85838, 0xc0001ab2c0}, {0x1a693c0, 0xc00056d6a0}, 0xc000488ac0, 0x0) 
github.com/xtls/xray-core/proxy/proxy.go:768 +0x9c2 
github.com/xtls/xray-core/proxy/freedom.(*Handler).Process.func4() 
github.com/xtls/xray-core/proxy/freedom/freedom.go:221 +0x266 
github.com/xtls/xray-core/proxy/freedom.(*Handler).Process.OnSuccess.func9() 
github.com/xtls/xray-core/common/task/task.go:12 +0x22 
github.com/xtls/xray-core/common/task.Run.func1(0xc000642ab0?) 
github.com/xtls/xray-core/common/task/task.go:28 +0x28 
created by github.com/xtls/xray-core/common/task.Run in goroutine 681 
github.com/xtls/xray-core/common/task/task.go:27 +0xdb

Worth to note, that 3xui run with docker

<!-- gh-comment-id:3948984470 --> @gallyamb commented on GitHub (Feb 24, 2026): The same for me. xray 26.2.6. 3xui 2.8.10 When there is no any connections to the xray, the core stays "stable". When connection is established it's crashed. Between crashes some data is proxied, though. But it crashes every 5-10 seconds Stacktrace is identical, but providing it anyway <details> <summary>Stacktrace</summary> ``` Core crash detected: panic: runtime error: slice bounds out of range [540:179] goroutine 698 [running]: github.com/xtls/xray-core/common/buf.(*Buffer).Extend(...) github.com/xtls/xray-core/common/buf/buffer.go:153 github.com/xtls/xray-core/proxy.XtlsPadding(0xc000584fc0, 0x2, 0xc000572318, 0x17?, {0x1a7d1e0, 0xc0001abef0}, {0xc000295590?, 0x4?, 0xc00067ee01?}) github.com/xtls/xray-core/proxy/proxy.go:519 +0x79e github.com/xtls/xray-core/proxy.(*VisionWriter).WriteMultiBuffer(0xc0005722d0, {0xc000053500, 0x1, 0x1}) github.com/xtls/xray-core/proxy/proxy.go:374 +0x51f github.com/xtls/xray-core/app/dispatcher.(*SizeStatWriter).WriteMultiBuffer(0xc00056d6a0, {0xc000053500, 0x1, 0x1}) github.com/xtls/xray-core/app/dispatcher/stats.go:16 +0x68 github.com/xtls/xray-core/proxy.CopyRawConnIfExist({0x1a7d1a8, 0xc000425d10}, {0x1a85940?, 0xc000053358?}, {0x1a85838, 0xc0001ab2c0}, {0x1a693c0, 0xc00056d6a0}, 0xc000488ac0, 0x0) github.com/xtls/xray-core/proxy/proxy.go:768 +0x9c2 github.com/xtls/xray-core/proxy/freedom.(*Handler).Process.func4() github.com/xtls/xray-core/proxy/freedom/freedom.go:221 +0x266 github.com/xtls/xray-core/proxy/freedom.(*Handler).Process.OnSuccess.func9() github.com/xtls/xray-core/common/task/task.go:12 +0x22 github.com/xtls/xray-core/common/task.Run.func1(0xc000642ab0?) github.com/xtls/xray-core/common/task/task.go:28 +0x28 created by github.com/xtls/xray-core/common/task.Run in goroutine 681 github.com/xtls/xray-core/common/task/task.go:27 +0xdb ``` </details> Worth to note, that 3xui run with docker
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
MHSanaei/3x-ui#2595
No description provided.