chiark / gitweb /
contrib/sshsvc.conf: Include configuration file for `sshsvc-mkauthkeys'.
authorMark Wooding <mdw@distorted.org.uk>
Sat, 2 May 2015 16:05:20 +0000 (17:05 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Fri, 8 May 2015 18:26:46 +0000 (19:26 +0100)
contrib/Makefile.am
contrib/sshsvc.conf [new file with mode: 0644]
debian/tripe.install

index 3bd4591..1fcf003 100644 (file)
@@ -25,6 +25,7 @@
 
 include $(top_srcdir)/vars.am
 
+dist_noinst_DATA        =
 noinst_DATA             =
 noinst_SCRIPTS          =
 
@@ -98,4 +99,7 @@ knock: knock.in Makefile
        $(SUBST) $(srcdir)/knock.in >$@.new $(SUBSTITUTIONS) && \
                chmod +x $@.new && mv $@.new $@
 
+## Configuration for `sshsvc-mkauthkeys'.
+dist_noinst_DATA       += sshsvc.conf
+
 ###----- That's all, folks --------------------------------------------------
diff --git a/contrib/sshsvc.conf b/contrib/sshsvc.conf
new file mode 100644 (file)
index 0000000..9537164
--- /dev/null
@@ -0,0 +1,12 @@
+### -*-sh-*-
+
+cmd="bin/knock"
+
+make_key_line () {
+  user=$1
+  case "$user" in
+    %gw:*) e=TRIPE_GATEWAY=${user#*:} ;;
+    *) e=TRIPE_USER=$user ;;
+  esac
+  echo "environment=\"$e\""
+}
index b435f6d..be519d8 100644 (file)
@@ -13,6 +13,7 @@ debian/build/contrib/ipif-peers               /usr/share/doc/tripe/examples
 debian/build/contrib/tripe-upstart     /usr/share/doc/tripe/examples
 debian/build/contrib/greet             /usr/share/doc/tripe/examples
 debian/build/contrib/knock             /usr/share/doc/tripe/examples
+contrib/sshsvc.conf                    /usr/share/doc/tripe/examples
 debian/build/contrib/tripe.service     /usr/share/doc/tripe/examples
 debian/build/contrib/tripe-conntrack.service /usr/share/doc/tripe/examples
 debian/build/contrib/tripe-connect.service /usr/share/doc/tripe/examples