Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,12 @@ fun buildSingBoxOutboundAmneziaWGBean(bean: AmneziaWGBean): SingBoxOptions.Outbo
if (bean.jmax != 0) jmax = bean.jmax
if (bean.s1 != 0) s1 = bean.s1
if (bean.s2 != 0) s2 = bean.s2
if (bean.s3 != 0) s3 = bean.s3
if (bean.s4 != 0) s4 = bean.s4
// The bundled amneziawg-go v1.0.4 UAPI does not accept s3/s4 yet.
// Zero values are safe to omit, but non-zero values would otherwise be
// silently ignored and produce a misleading tunnel configuration.
if (bean.s3 != 0 || bean.s4 != 0) {
error("AmneziaWG S3/S4 are not supported by the bundled core")
}
if (bean.h1.isNotBlank()) h1 = bean.h1
if (bean.h2.isNotBlank()) h2 = bean.h2
if (bean.h3.isNotBlank()) h3 = bean.h3
Expand Down
Loading