#8 Redefine msg_1 to prevent fail

open
Jon Wallace
libpam (2)
5
2009-05-27
2009-05-27
sunss
No

In test_vsftpd.bash, the msg_1 is defined as follow:

msg_1="acct=\"*$TEST_USER\"* : exe=./usr/sbin/vsftp.*hostname=localhost.*, addr=127.0.0.1, terminal=ftp res=success.*"
Which will cause test failure if the hostname is not “localhost”.

For we are already searching on the IP address itself so searching on the hostname is almost certainly redundant,
I suggest changing "msg1" to something like this:
"acct=\"*$TEST_USER\"* : exe=./usr/sbin/vsftp.*, addr=127.0.0.1, terminal=ftp res=success.*"
And then verifying that everything still works as expected.

There is the same problem in test_vsftpd_fail.bash.

Discussion

  • sunss
    sunss
    2009-05-27

    Redefine msg_1 to prevent fail when the hostname is not "localhost"