summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorRobert Ancell <robert.ancell@canonical.com>2015-11-17 13:57:35 +1300
committerRobert Ancell <robert.ancell@canonical.com>2015-11-17 13:57:35 +1300
commitec217852d8c3fa04c7aca8a34d02f60070f88701 (patch)
treee61478892c943dfdd0524a38105550f598c60d96 /tests
parent59b8d005821cb60f00a5119d8022f314bb38c1db (diff)
downloadlightdm-ec217852d8c3fa04c7aca8a34d02f60070f88701.tar.gz
Handle XDMCP Request packet with no addresses
Diffstat (limited to 'tests')
-rw-r--r--tests/Makefile.am2
-rw-r--r--tests/scripts/xdmcp-server-request-without-addresses.conf33
-rwxr-xr-xtests/test-xdmcp-server-request-without-addresses2
3 files changed, 37 insertions, 0 deletions
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 6262a78e..ebb88b60 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -179,6 +179,7 @@ TESTS = \
test-xdmcp-server-login \
test-xdmcp-server-double-login \
test-xdmcp-server-guest \
+ test-xdmcp-server-request-without-addresses \
test-utmp-login \
test-utmp-autologin \
test-utmp-wrong-password \
@@ -599,6 +600,7 @@ EXTRA_DIST = \
scripts/xdmcp-server-guest.conf \
scripts/xdmcp-server-login.conf \
scripts/xdmcp-server-open-file-descriptors.conf \
+ scripts/xdmcp-server-request-without-addresses.conf \
scripts/xremote-autologin.conf \
scripts/xremote-login.conf \
scripts/xserver-config.conf \
diff --git a/tests/scripts/xdmcp-server-request-without-addresses.conf b/tests/scripts/xdmcp-server-request-without-addresses.conf
new file mode 100644
index 00000000..4a42606f
--- /dev/null
+++ b/tests/scripts/xdmcp-server-request-without-addresses.conf
@@ -0,0 +1,33 @@
+#
+# Check remote X server sending a request without connections is ignored
+#
+
+[LightDM]
+start-default-seat=false
+
+[XDMCPServer]
+enabled=true
+
+[test-xserver-config]
+xdcmp-empty-request=true
+
+#?*START-DAEMON
+#?RUNNER DAEMON-START
+#?*WAIT
+
+# Start a remote X server to log in with XDMCP
+#?*START-XSERVER ARGS=":98 -query 127.0.0.1 -nolisten unix"
+#?XSERVER-98 START LISTEN-TCP NO-LISTEN-UNIX
+
+# Start sending XDMCP queries
+#?*XSERVER-98 START-XDMCP
+#?XSERVER-98 SEND-QUERY
+
+# Negotiate with daemon
+#?XSERVER-98 GOT-WILLING AUTHENTICATION-NAME="" HOSTNAME="" STATUS=""
+#?*XSERVER-98 SEND-REQUEST ADDRESSES="" AUTHORIZATION-NAMES="MIT-MAGIC-COOKIE-1" MFID="TEST XSERVER"
+#?XSERVER-98 GOT-DECLINE STATUS="No valid address found" AUTHENTICATION-NAME=""
+
+# Clean up
+#?*STOP-DAEMON
+#?RUNNER DAEMON-EXIT STATUS=0
diff --git a/tests/test-xdmcp-server-request-without-addresses b/tests/test-xdmcp-server-request-without-addresses
new file mode 100755
index 00000000..ccdcad17
--- /dev/null
+++ b/tests/test-xdmcp-server-request-without-addresses
@@ -0,0 +1,2 @@
+#!/bin/sh
+./src/dbus-env ./src/test-runner xdmcp-server-request-without-addresses test-gobject-greeter