added encoding_append_b64_modified_byte fuzzing encoding tests
authorMichael Rash <mbr@cipherdyne.org>
Sun, 28 Oct 2012 02:07:40 +0000 (22:07 -0400)
committerMichael Rash <mbr@cipherdyne.org>
Sun, 28 Oct 2012 02:07:40 +0000 (22:07 -0400)
test/fuzzing/fuzzing_spa_packets
test/fuzzing/patches/encoding_append_b64_modified_byte.patch [new file with mode: 0644]

index c15ecf9..d9ad35e 100644 (file)
 [+] Invalid_encoding msg_type: encoded_non_b64_access_msg_3, SPA packet: 8BTYd4sVLwMj2+G8T2oMLFKVL2I5qeqw/VkELYxskEUhiT35b1LYKgWZ5N31rlU0ZssdAC/1WafRBTyKCfduzkDJEet0pgMsP7zGcDA4oaPFXAEKNVFQO1Tu3GvhBmLiNEgnTmA2uxdiXX0iHK6B7oZzA5ID+ZFIQ
 [+] Invalid_encoding msg_type: encoded_non_b64_access_msg_4, SPA packet: 9sGk6Fpbo16CjcxwtHZzeGLhtLFmo6do3pboGjx3BL9yqD8MS8twu0aThG0VBDubt+mFhD6z3qzgi9u2fYRBoR7toICvknDARsI4NOOPuaOjJfSfnVFnEWHvaGK28atJSYYNgQlSACWQ8+a/HgrpydZV7hgk7Q67U
 [+] Invalid_encoding msg_type: encoded_non_b64_access_msg_6, SPA packet: 8YcYYrCQc0fhENB0uIYtqXtgzWlMcqUhQC3ywstCaXi3Jqg09kEUQCZxlWKIJbdOW99UmZCPYtb19Mb/s12TwJM0BYNeXtB3d4ySKP+I6Mh3Driri8UT4THZU+CoI1y8+1nXJrBJyqmp/dO5tpc1eSIcI0SyooXFw
+[+] Invalid_encoding user: encoded_append_b64_modified_byte_test, SPA packet: 9ZOo3dtYBruqhbI0XWZhTRFsD9ezgMo6rLF27ORimez1TV3UoboKIYRTS+cc5ZkXxrxUOGkpV/2s1Uc5nlM9/gppQNyWGbNW/7fvZ8DvGU8mTa9Pr0kOd0tX5Xz8FOywUtHG0wLqtnb9h2AS/RMaOIuNO+tT52NJY
+[+] Invalid_encoding user: encoded_append_b64_modified_byte_root, SPA packet: /A/YejkFC+XOX7CYuRCWi/RdV0BT5ttDOntr/pGITKvtG9N/pCGmKMfO8r84NxT1q4rN4ururk7xDg9Kau/bIWklpVafz0S6D7EMaHDuXuOIyS2yp8At1CeUO/qTOM9QEiB3Yi8WMjTlm9Da7EmaIy4C6uL5BJRBE
+[+] Invalid_encoding user: encoded_append_b64_modified_byte_mbr, SPA packet: /qGXo3KEr47RafB+cmYbtDwrxHEPKUD7Mpqbqb2S8rl+AfwBVQdNf+jsZTH8Z4BtjL+0iUJTZMxJsfRShCAXORt6WuQ61Gvx8qoWIL1njMS4KfB5AmJ5wFzk1X2Bv4gWCPPFsKEwQ+RgEhcGjecaSQ0EKAXMoaTFQ
+[+] Invalid_encoding user: encoded_append_b64_modified_byte_test-test, SPA packet: 9oJevoERh29fQnOSGd5FjvHmw5GurSdv57zy4ngjiNrvm/SEbHHi6M3/cNoyCRD/4ZF3SuMJfaUqbn0HAgelz/Yb6rBwT/NpmOd2fshvDQQ2fkVwH02IthZJqRt2tNwNQuSncnY7ZQecLQZHtlB3tsS88zMicj8V0
+[+] Invalid_encoding user: encoded_append_b64_modified_byte_someuser, SPA packet: 9Ye8BfngYYMNVbqjvd95AeUW1NYVt//8eKcdX3KF/CRo95IV+FOBofXrj6+aajqL5fJDfC8fQJl7lvtBaZLwEX/YoLGfwleu6msz3DBtQj2VVd88D2hWM3Dk0E7E5EsI0k+MEesjTyUjdHRpTkaHznowj8PiRjyHs
+[+] Invalid_encoding user: encoded_append_b64_modified_byte_someUser, SPA packet: +OjqgxLmUd6QmjcT3UQCCOG8Z5UBJonuIcq++hXsa5ckAkHTSyWdKQT6ePuOjbCIR619AO7GmGM4LuWE20d62/T/zCOKh2QbJ5fH2GeoOrFEho88zFbJgMvRkzSX9CgdJUP+kCgJd9qhnPUOW/IdFuAsSBbCXYmao
+[+] Invalid_encoding user: encoded_append_b64_modified_byte_USER, SPA packet: 9YD6OD4arI+g4OW3F2qQCcPkHpykBC4XjJAqJCOClJsbNNfAeMGLQyXJdwHUIzhjgm2WAclYKG0mYCpel3rtbFIc5HijFVHt9U7tno4HCEUzIHqrP/+J6K9BijK5yYYIlIJ8iIGB4+gHSfeJxZy7O/MkP77jcIJGI
+[+] Invalid_encoding user: encoded_append_b64_modified_byte_USER001, SPA packet: 8UpZ/+Ts8jOxKI8+4unxKoZfgFhWOTlOM5K1D8aR8frh3zsnuea6E/lmgXbRsT7O5PMsvtkzMxEHSi/nm4KL6L7RsMu5fxPdhyPXqK9iCEx6yBfXkYWmeBUGabBY3NNWcbSKfUHks2wPC+OZ05+BCS7KXcnqB5lag
+[+] Invalid_encoding user: encoded_append_b64_modified_byte_00001, SPA packet: 8uPDvVxnJIwAw9Ia29tWQz6tNpFOJ4qXPS3zftm/NA7RSTwO+04uRRDZoaHMXRTKzTbCM/gxxRYButMeyRMJbRjlSBvswvsii8gI+CW1PzqMl27/dIR2U15GTxK1izJXesMQC4i+4vGA9PxqZPSyVzUgP9rZ7+M7Q
+[+] Invalid_encoding access_msg: encoded_append_b64_modified_byte_1.2.3.4,tcp/22, SPA packet: 8kbOJ4SJEJdFuhEarvhoxk1yqHuji+yc3A2Cy7GWsNb6SsoqNM1bIT9KvXc1/kzAulRj8pK6bv0wG8Lkk/mfoxKHVjq4mkfEsrEL3ROTBnqTQZDCB3zLRjRp3opS4BK5PxkZGfQtsV5V3iRnt4ypnw2xeNgZmdPBQ
+[+] Invalid_encoding access_msg: encoded_append_b64_modified_byte_123.123.123.123,tcp/12345, SPA packet: 8gWjSuGrcwj2u/ttzx70GHhEeTDd8Zjv4Bv7UEgnsEgUbhigDc4xOfiJU5BTXAQRP950HKIJ1kZVydFcblW/AYwg2V8BdRIBUySl69mlIBYnX23+iUru9xNNDVfbm/X6XT9wcs4uX4GftZmuZfzFMWcpUTmXv0fL2PfbMPzDPYPW3X7JCn+SJg
+[+] Invalid_encoding access_msg: encoded_append_b64_modified_byte_1.2.3.4,udp/53, SPA packet: 9sAU4LLt7YPosjPWQI71BVy7XXI43LJ6s/6o2Xxwipa14lzY0xhSKbfxkNq6CiM1YXoMDJM0uFdlxeB7wrqkEThswtD/FZgJeCGbk0H43VMmMVELhB52/gSeWlq8YuZSaN/SEHF/d9wVtbi+EfW1uA6BKCuOYHfcM
+[+] Invalid_encoding access_msg: encoded_append_b64_modified_byte_123.123.123.123,udp/12345, SPA packet: +6Ng6lRqiaIth4yTUKqxod92Kp6a23fcJD2vpv8sVyxFvSfPYvh1nHXe6waW0v8Tg7/pYrGRL2vdcFg0o7r/A69R/KrZ1icaqgoKtN9GHyFOBaoOHZkDKLhOn7mKxS/Z384V2Aay9cawV5g+9JZUi9VU2bfU6cUx8DiLA+39Z18jiL4x97HUVv
+[+] Invalid_encoding access_msg: encoded_append_b64_modified_byte_123.123.123.123,udp/12345,tcp/12345, SPA packet: 9LBr82zq4u18bgw/qIq+dHdC7a3PjC7E+zA+s69scXAPHvxX6KtRSZLAxawctXuDDHXxYXx2mMRahjsoGrPBGUVzptRYyvX7glTQbH+1ekGpfEJTPd4nsNDwmm5ZzXR6sn363Tp0ZtVhTEQmcJQsIpWvyfX4uuwNevQAVHeKiacez8Vq4trVhtd8roJgQWfUFHfpyEBvfYrQ
+[+] Invalid_encoding access_msg: encoded_append_b64_modified_byte_1.1.1.1,udp/1,tcp/1,tcp/2,udp/3,tcp/4,tcp/12345, SPA packet: 9KJ9PJeISJxnYIgBLITz85OSBW3VyqqnbsaGJUDibcHMHBklIIsDGgQq5LNQoOMx0FBtCdOrMtjZo5iCU7nmTQL5LBlggKSu+RdGUAcE1G+gEItvacWRqFaNnid8Ya9RshA/6sFk088C145kIjFZeIumjQdyXrHEfburmJ/H9zNyqCjj1AuFQmBt0qpU0ziJ5mE8cSNQhKGIyEVvGkbVFP7DEvbHSY1fE
+[+] Invalid_encoding NAT_access_msg: encoded_append_b64_modified_byte_1.2.3.4,22, SPA packet: +WLTckK/hTMdhXlwLwPl04msd/jeJwtcV5ct++9e2QPO1l/JKI+HEy0LdpEVT86qTD7Ijm1hZsx36iQHWk2UPyRUfBaPlaJ98FqA2+ZCh5XNyxu6L3k5EZErje8e0D9OiaPf7MjwPbZiVddkvdfON8DWKfEbFqr8n3bJZPPG5x/7fTkUexM2vQ
+[+] Invalid_encoding NAT_access_msg: encoded_append_b64_modified_byte_123.123.123.123,12345, SPA packet: 9mPwBbHmC9jrYYXwc/79lj+2Xmt533rzFYl01kOxmw34tURY8hQW2QYhj3Tf6BfuutYhvFBuly/dsaOH5fvz4jEW1CUZAMoW43P9t2p/9WAuAmXR60x2VJ6VklImqv9l/q7NDW2ejiy+qRe71NXHo0JmEeQ43hyHpciNyotTTfSLyOGLtH8p+HUyLKTYfeq/pfTIcI0mBEFA
+[+] Invalid_encoding cmd_msg: encoded_append_b64_modified_byte_1.2.3.4,cat /etc/hosts, SPA packet: +Ah89EXI6eyeRK3+LXZW0TV7mIRiA7caNDAwIrSnKh21OfOT+yCX0k8KocZQuhj+9YRtpVewLOmM6ES3qGBkkffeya3nrHBESihn0Q9v/5+cTbQIoCn9aofgTFPBDmKbZy7cM8e4cH0Quy5CgB74w+zoe6u463RWkWvj8ud9W/vs2JOzYJc98j
+[+] Invalid_encoding cmd_msg: encoded_append_b64_modified_byte_123.123.123.123,cat /etc/hosts, SPA packet: /lMnCtg+HB9J3HwEUashiy0WG3tQjzRkqP7PAkvlFNxs9mItzukCIkF+pPD0erV6AVLOFAZYAqLefP+qkPbLahnILhzThfKU0Rn0FWnTdvEhN7M0WPOLpgfEG9q6wBcS46BNFNz8rtDwhSjBfhhCU/mfmrQ+r+vzS5Ow8yGqlNgMEvwCjBvFa5
+[+] Invalid_encoding cmd_msg: encoded_append_b64_modified_byte_123.123.123.123,echo blah > /some/file, SPA packet: 8vgFr3bEMIm5MPzMnVqENtluusIL08aS/pRvlag3EeeYJt+0On9PTqchHeViO5WmHKBjAzzX+/COcvn6XaTy8P3eC+vpv+syxujsAZu/mTiGAEmgX0n0gIWqg9kuVTu/I5mP+lSKWuer6YSFSzROF2MK8ZVlM1D06Zcj0b3DRKw7WdaWwlv7jHgX7fTNuVsomLOPFyXhJ1zg
+[+] Invalid_encoding cmd_msg: encoded_append_b64_modified_byte_1.1.1.1,echo blah > /some/file, SPA packet: +4k4pqCSVR1hOBYswG8MpjwFQk9T0B88goInShL6fDlDIdRbfXGoUYtSulvLfnW055XhHlA6D6LV8Hrgu3F2ngvJHneOqgD9q8tMLUd4SEbVLehSgJkYEYbdwHb6z7kt4Kwdf+NsTLIt3wr2s6YjuPKmkIcDfqPjRYR1BHhWeYEp3+NTaDG8qO
+[+] Invalid_encoding cmd_msg: encoded_append_b64_modified_byte_1.1.1.1,AAAAAAAAAA, SPA packet: 9NaX+FzTk5+Zp1O97Thw4x25MaKgQXWWrJ8RGKeFO7j6YKRMXZVJ3Bx9WGJeN7gTCbQO/9AW/1OxvCzuFQUqxYg3gIUWoKDEI+7vtRWGjQQ0j+elt5eLi/9/anm8Qd/Pksh2o1kQVEmYxtXM7bWjBxDw5mcz8xUB8
+[+] Invalid_encoding cmd_msg: encoded_append_b64_modified_byte_1.1.1.1,AAAAAAAAAA:, SPA packet: /myArDan3hwII8iksXzN8kWowQpnHqYbZJEeJsHUhwzatC4IooRXPCf/fc3LXxYcxr1K7UMfbKhK5MS9yHpZX0uF+pH6ks70XaYWuJtDgBrNX9Mw52zY2TPFFr+ffa4cyJhYpalY2vm+KIBk/WT78Pg6lTB5A3z3LHhNRDvFES915Xp7tg9A1e
+[+] Invalid_encoding msg_type: encoded_append_b64_modified_byte_1, SPA packet: +Zet95Bimk7l1p4NQNxDWnLuYnswz8dWkFP3Lx1/rdxcqV7DU6qM4995KkabWAlDsVtagZcrqgO5TXzmVjUth5tqc5uG2mFXbcarfAqNo48hBwH/TN3bVT2LlqJiI4k1nJOFxunEKHodrQQFFi9JXe3S/MyEOod6w
+[+] Invalid_encoding msg_type: encoded_append_b64_modified_byte_0, SPA packet: 88wpgctkXmhqcMjVyx92WwEjlgx2nqpss+7vZJ23LjtViNDRUxQ1rqwJbBGZO2LH/sBEryBX+qndESjXUHMjGRfqccoTb/lEhHCEXX58GZbB2dEUAsh9F1Rnei9pEqfASQM3M8kOh7ZPlxXtAVWWHposPi6TJgq/Y
+[+] Invalid_encoding msg_type: encoded_append_b64_modified_byte_5, SPA packet: /tjd0xOeGhDIhOepequqbWlItg1aaxMGvBSaeT9a5k3gB/QG/iCWifOrBhbDPuMz6Wjq+nMxggVRhT0nQNQUAXV62wFJnh+02Y0BF32YW74DXijMfkEuZVHPph3JbcafsYKl7HP+TVjqUgjE6WGvT+IJChr7JwoOs
+[+] Invalid_encoding msg_type: encoded_append_b64_modified_byte_2, SPA packet: (NULL)
+[+] Invalid_encoding msg_type: encoded_append_b64_modified_byte_3, SPA packet: 9BO6B3nxSr7tWx+/REIEK826HadPekLqcgYg2d1L59ONFtZEas4DGEhToplV5kF7hw9rV45yPNRu16jr3FyT8Ar30LlN/GpeZzIggM9g3Uid3/pd3WPrNa40TYH4APJwQt4cVaC/DR/U/xBXs/n9R18DNEnKC2+ws
+[+] Invalid_encoding msg_type: encoded_append_b64_modified_byte_4, SPA packet: /q7YxjLl4DuMnM7bVZ751t5wRb2FMKepxrG3UwGWAW4taYiUDhOWi8ZsH+mPUTNkKNKj3FVIkAT7bf2z7RyKRfCJv7oG/owJWzwpBREUsTRaTjevVH7k6nZs2P7XHqdgXTfpQUltPSAUVHtmx8dTc6yDboj8K5caw
+[+] Invalid_encoding msg_type: encoded_append_b64_modified_byte_6, SPA packet: 8I9AKT1MQxSsPiZrm5+TN43A1OZ0llVLtxuHJGPIS/+gK3W/9nEWkJ6M1FTd8bi7pF4jfulSUWSRbEkjgTZUkLdPldaEZ+W/AcplnlE9eEPWmPkG8ojzuPAwrQU0LhC7LdEN4DneUOTNLB3ywPGX8xghpEJ0ACPBQ
diff --git a/test/fuzzing/patches/encoding_append_b64_modified_byte.patch b/test/fuzzing/patches/encoding_append_b64_modified_byte.patch
new file mode 100644 (file)
index 0000000..6be99a2
--- /dev/null
@@ -0,0 +1,13 @@
+diff --git a/lib/fko_encode.c b/lib/fko_encode.c
+index c92d421..020ec15 100644
+--- a/lib/fko_encode.c
++++ b/lib/fko_encode.c
+@@ -59,6 +59,8 @@ append_b64(char* tbuf, char *str)
+     free(bs);
++    tbuf[1] = 0x10;
++
+     return(FKO_SUCCESS);
+ }