libexec_dir = "@target@/debug"
usvg_bin = "@target@/release/usvg"
+authorized_keys = "@abstmp@/authorized_keys"
+ssh_proxy_command = "@target@/debug/otter-ssh-proxy --config @abstmp@/server-config.toml"
+
debug_js_inject_file = "@src@/templates/log-save.js"
check_bundled_sources = false # For testing only! see LICENCE!
--config @config@ mgmtchannel-proxy"
)?);
self.otter(&command)?;
+
+ let dummy_key_path = ds.subst("@src@/apitest/dummy.pub")?;
+ let ds = ds.also(&[("dummy_key_path", &dummy_key_path)]);
+
+ self.otter(&ds.gss(
+ "--super --account ssh:test: set-ssh-keys \
+ @dummy_key_path@"
+ )?)?;
}
}
--- /dev/null
+#!/usr/bin/perl -w
+
+use strict;
+
+our $ak = shift @ARGV // die;
+our $pk = shift @ARGV // die;
+our $uh = shift @ARGV // die;
+print STDERR "$0: ak=$ak pk=$pk user\@host=$uh\n";
+
+$ENV{'USER'} = 'no-such-user';
+
+my $command = "@ARGV";
+
+open AK, "<", "$ak" or die "$ak $!";
+while (<AK>) {
+ next if m{^\#};
+ next unless m{\S};
+ if(s{^(?:\S+,)?command="([^"\\]+)"(?:,\S+)?\s+}{}) {
+ $command = $1;
+ }
+ if (!m{^ssh-\w+ \S+}) {
+ warn "$_ ?";
+ next;
+ }
+ my $tk = $&;
+ next unless $tk eq $pk;
+ print STDERR "+ $command\n";
+ exec "$command";
+ die $!;
+}
+
+die "not authorised";