X-Git-Url: https://git.archive.openwrt.org/?a=blobdiff_plain;f=protocols%2Fluci-proto-wireguard%2Fluasrc%2Fmodel%2Fcbi%2Fadmin_network%2Fproto_wireguard.lua;h=d9500811978e485ba59834d4b86bb6e954f8fa02;hb=refs%2Fpull%2F1015%2Fhead;hp=de4ece3471a0a033a98bd924b28925be95399369;hpb=a9463d3d1a8febd27703fc421a5ed3335f81ded2;p=project%2Fluci.git diff --git a/protocols/luci-proto-wireguard/luasrc/model/cbi/admin_network/proto_wireguard.lua b/protocols/luci-proto-wireguard/luasrc/model/cbi/admin_network/proto_wireguard.lua index de4ece347..d95008119 100644 --- a/protocols/luci-proto-wireguard/luasrc/model/cbi/admin_network/proto_wireguard.lua +++ b/protocols/luci-proto-wireguard/luasrc/model/cbi/admin_network/proto_wireguard.lua @@ -19,7 +19,7 @@ private_key = section:taboption( translate("Required. Base64-encoded private key for this interface.") ) private_key.password = true -private_key.datatype = "rangelength(44, 44)" +private_key.datatype = "and(base64,rangelength(44, 44))" private_key.optional = false @@ -76,11 +76,12 @@ preshared_key = section:taboption( Value, "preshared_key", translate("Preshared Key"), - translate("Optional. Adds in an additional layer of symmetric-key " .. + translate("Optional. Base64-encoded preshared key. " .. + "Adds in an additional layer of symmetric-key " .. "cryptography for post-quantum resistance.") ) preshared_key.password = true -preshared_key.datatype = "rangelength(44, 44)" +preshared_key.datatype = "and(base64,rangelength(44, 44))" preshared_key.optional = true @@ -102,9 +103,9 @@ public_key = peers:option( Value, "public_key", translate("Public Key"), - translate("Required. Public key of peer.") + translate("Required. Base64-encoded public key of peer.") ) -public_key.datatype = "rangelength(44, 44)" +public_key.datatype = "and(base64,rangelength(44, 44))" public_key.optional = false