Add Mieru inbound, refactor sudoku. Fixes

This commit is contained in:
Shtorm
2026-06-04 07:54:26 +03:00
parent 195a33379d
commit e363c2ff78
30 changed files with 947 additions and 342 deletions

View File

@@ -1,28 +1,26 @@
package option
import "github.com/sagernet/sing/common/json/badoption"
type SudokuOutboundOptions struct {
DialerOptions
ServerOptions
Key string `json:"key"`
AEADMethod string `json:"aead_method,omitempty"`
PaddingMin *int `json:"padding_min,omitempty"`
PaddingMax *int `json:"padding_max,omitempty"`
TableType string `json:"table_type,omitempty"`
EnablePureDownlink *bool `json:"enable_pure_downlink,omitempty"`
CustomTable string `json:"custom_table,omitempty"`
CustomTables []string `json:"custom_tables,omitempty"`
HTTPMask *SudokuHTTPMask `json:"http_mask,omitempty"`
Key string `json:"key"`
AEADMethod string `json:"aead_method,omitempty"`
PaddingMin *int `json:"padding_min,omitempty"`
PaddingMax *int `json:"padding_max,omitempty"`
TableType string `json:"table_type,omitempty"`
EnablePureDownlink *bool `json:"enable_pure_downlink,omitempty"`
CustomTable string `json:"custom_table,omitempty"`
CustomTables []string `json:"custom_tables,omitempty"`
HTTPMask *SudokuHTTPMask `json:"http_mask,omitempty"`
}
type SudokuHTTPMask struct {
Enabled bool `json:"enabled,omitempty"`
Mode string `json:"mode,omitempty"`
Host string `json:"host,omitempty"`
PathRoot string `json:"path_root,omitempty"`
Multiplex string `json:"multiplex,omitempty"`
TLS *SudokuOutboundTLSOptions `json:"tls,omitempty"`
Enabled bool `json:"enabled,omitempty"`
Mode string `json:"mode,omitempty"`
Host string `json:"host,omitempty"`
PathRoot string `json:"path_root,omitempty"`
Multiplex string `json:"multiplex,omitempty"`
OutboundTLSOptionsContainer
}
type SudokuInboundOptions struct {
@@ -41,14 +39,3 @@ type SudokuInboundOptions struct {
PathRoot string `json:"path_root,omitempty"`
Fallback string `json:"fallback,omitempty"`
}
type SudokuOutboundTLSOptions struct {
Enabled bool `json:"enabled,omitempty"`
Fragment bool `json:"fragment,omitempty"`
FragmentFallbackDelay badoption.Duration `json:"fragment_fallback_delay,omitempty"`
RecordFragment bool `json:"record_fragment,omitempty"`
KernelTx bool `json:"kernel_tx,omitempty"`
KernelRx bool `json:"kernel_rx,omitempty"`
}