mirror of
https://gitlab.freedesktop.org/dbus/dbus.git
synced 2026-02-05 14:40:28 +01:00
test: Add a test for authenticating with an empty authorization identity
Signed-off-by: Simon McVittie <smcv@collabora.com> Reviewed-by: Philip Withnall <withnall@endlessm.com> Bug: https://bugs.freedesktop.org/show_bug.cgi?id=104588
This commit is contained in:
parent
064c478e14
commit
8a4928af76
2 changed files with 19 additions and 0 deletions
|
|
@ -472,6 +472,7 @@ static_data = \
|
|||
data/auth/anonymous-server-successful.auth-script \
|
||||
data/auth/cancel.auth-script \
|
||||
data/auth/client-out-of-mechanisms.auth-script \
|
||||
data/auth/external-auto.auth-script \
|
||||
data/auth/external-failed.auth-script \
|
||||
data/auth/external-root.auth-script \
|
||||
data/auth/external-silly.auth-script \
|
||||
|
|
|
|||
18
test/data/auth/external-auto.auth-script
Normal file
18
test/data/auth/external-auto.auth-script
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
# Test that we can authenticate with an empty authorization identity
|
||||
SERVER
|
||||
EXPECT_HAVE_NO_CREDENTIALS
|
||||
|
||||
# C: "I want to use EXTERNAL, I decline to specify an initial response"
|
||||
SEND 'AUTH EXTERNAL'
|
||||
# S: "OK, who do you claim to be?"
|
||||
EXPECT_COMMAND DATA
|
||||
EXPECT_STATE WAITING_FOR_INPUT
|
||||
EXPECT_HAVE_NO_CREDENTIALS
|
||||
# C: "I am whoever the kernel says I am"
|
||||
SEND 'DATA'
|
||||
# S: "I suppose I can't argue with that"
|
||||
EXPECT_COMMAND OK
|
||||
EXPECT_STATE WAITING_FOR_INPUT
|
||||
SEND 'BEGIN'
|
||||
EXPECT_STATE AUTHENTICATED
|
||||
EXPECT_HAVE_SOME_CREDENTIALS
|
||||
Loading…
Add table
Reference in a new issue