commit 6bb09cecb3e598c98ba7f9d724a18bd07190d35a from: Vladimir Davydov date: Mon Oct 16 15:33:18 2023 UTC console: forward original URI to net.box when connecting over IPROTO Tarantool supports two console protocols: text and binary. The binary protocol is implemented with IPROTO EVAL request so the console module reuses the net.box module to establish and maintain a binary connection. Currently, instead of passing the original URI specified by the user to net.box.connect as is, the console module parses the URI and passes the host and port. As a result, extra information that may be specified in URI parameters is lost. This prevents the user from connecting to the binary console using the SSL transport because to use the SSL transport the user must specify transport=ssl URI parameter. Needed for tarantool/tarantool-ee#567 NO_DOC=no visible changes in CE NO_TEST=no visible changes in CE NO_CHANGELOG=no visible changes in CE (cherry picked from commit 33e72567dc4f8f745be986190be08db847f423d0) commit - 1babcf1ea49d9c8823a706a36d1a12ef43733d28 commit + 6bb09cecb3e598c98ba7f9d724a18bd07190d35a blob - 57ece1262f090f32656a38ee780053d8f0531c28 blob + b97e9733f27540b23818e23506caab2e0162be37 --- src/box/lua/console.lua +++ src/box/lua/console.lua @@ -853,11 +853,7 @@ local function connect(uri, opts) -- We don't know if the remote end is binary or Lua console so we first try -- to connect to it as binary using net.box and fall back on Lua console if -- it fails. - local remote = net_box.connect(u.host, u.service, { - connect_timeout = opts.timeout, - user = u.login, - password = u.password, - }) + local remote = net_box.connect(uri, {connect_timeout = opts.timeout}) if remote.state == 'error' then local err = remote.error remote = nil