glib/gio/tests
Philip Withnall fcd2f7e639 tests: Add tests for the thumbnail verification code in GIO
This code was added for use by the G_FILE_ATTRIBUTE_THUMBNAIL_IS_VALID
file attribute, but may end up being used elsewhere (e.g. in GVfs) as well.
As it’s dealing with untrusted external files, and the non-trivial PNG file
format, this commit adds several test cases to cover valid and invalid PNG
files.

The security model for the thumbnail verification code is that the user’s
cache directory is untrusted, and potentially any PNG file which is passed
to the verifier has been manipulated arbitrarily by an attacker.

This is a follow-up to commit fe7069749f.

https://bugzilla.gnome.org/show_bug.cgi?id=709898
2013-10-24 13:55:33 -04:00
..
cert-tests Convert some gio tests to installed tests 2013-05-20 06:38:41 -04:00
gdbus-object-manager-example Rework the build system for a new tests approach 2013-05-31 23:12:15 -04:00
schema-tests Add a test for CDATA in gschema.xml files 2011-11-07 00:14:28 -05:00
services Adding test coverage for GTestDBus activating in-tree services. 2012-12-28 21:28:28 -05:00
thumbnails tests: Add tests for the thumbnail verification code in GIO 2013-10-24 13:55:33 -04:00
.gitignore tests: Add tests for the thumbnail verification code in GIO 2013-10-24 13:55:33 -04:00
actions.c add GPropertyAction 2013-07-11 12:35:45 -04:00
appinfo-test2.desktop Cleanups 2010-07-05 00:56:12 -04:00
appinfo-test-actions.desktop Add missing file 2013-07-11 13:49:20 -04:00
appinfo-test-gnome.desktop Add some more appinfo tests 2010-07-04 20:51:06 -04:00
appinfo-test-notgnome.desktop Add some more appinfo tests 2010-07-04 20:51:06 -04:00
appinfo-test.c Some final g_test_build_filename() porting 2013-05-31 23:03:19 -04:00
appinfo-test.desktop Improve GAppInfo test coverage 2012-08-19 02:23:32 -04:00
appinfo.c Rework the build system for a new tests approach 2013-05-31 23:12:15 -04:00
async-close-output-stream.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
async-splice-output-stream.c tests: Add testcases for g_output_stream_splice_async() 2013-09-29 17:48:40 -04:00
basic-application.c Improve GApplication test coverage 2012-06-04 06:04:28 -04:00
buffered-input-stream.c gio/tests: add some more async stream tests 2013-01-16 10:17:15 -05:00
buffered-output-stream.c Change semantics of seek on memory output stream 2013-10-23 11:31:27 -04:00
cancellable.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
contenttype.c tests: remove assertion for '!uncertain' on .txt 2013-09-12 14:40:24 -04:00
contexts.c Rename G_TEST_DISTED to G_TEST_DIST 2013-05-29 09:03:32 -04:00
converter-stream.c Improve test coverage for GZipCompressor 2013-06-02 01:41:50 -04:00
credentials.c gcredentials: add Solaris support 2013-10-04 09:51:31 -04:00
data-input-stream.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
data-output-stream.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
dbus-appinfo.c Add a testcase for DBusActivatable=true 2013-07-11 15:49:28 -04:00
de.po Merge GSettings tests 2010-04-17 01:48:05 -04:00
desktop-app-info.c Implement the Desktop Action specification 2013-07-11 12:48:08 -04:00
echo-server.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
enums.xml.template GSettings: major refactor. Add enums, range. 2010-06-16 18:17:53 -04:00
file.c tests: Remove a leftover debug printf 2013-06-02 09:53:24 -04:00
fileattributematcher.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
filter-cat.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
filter-streams.c gio/tests: add some more async stream tests 2013-01-16 10:17:15 -05:00
g-file-info.c Improve GFileAttributeMatcher test coverage 2013-06-02 01:43:13 -04:00
g-file.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
g-icon.c Improve GIcon test coverage 2013-06-02 01:42:28 -04:00
gapplication-example-actions.c Don't use deprecated GApplication api in examples 2011-12-08 18:05:15 -05:00
gapplication-example-cmdline2.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gapplication-example-cmdline3.c e G_SOURCE_CONTINUE/REMOVE internally 2012-01-25 16:15:18 -05:00
gapplication-example-cmdline.c Tweak GApplication docs 2010-11-02 23:02:05 -04:00
gapplication-example-dbushooks.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gapplication-example-open.c Tweak GApplication docs 2010-11-02 23:02:05 -04:00
gapplication.c tests: use new g_test_build_filename() API 2013-05-29 09:03:31 -04:00
gdbus-addresses.c g_dbus_address_escape_value: add 2013-02-13 20:42:58 +00:00
gdbus-auth.c gio/tests: Drop superfluous dbus-1 dependencies of gdbus-auth 2013-01-04 21:36:37 +01:00
gdbus-bz627724.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-close-pending.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-connection-flush-helper.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-connection-flush.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-connection-loss.c tests: use new g_test_build_filename() API 2013-05-29 09:03:31 -04:00
gdbus-connection-slow.c tests: move tests to new _get_filename() API 2013-05-29 09:03:32 -04:00
gdbus-connection.c tests: move tests to new _get_filename() API 2013-05-29 09:03:32 -04:00
gdbus-daemon.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-error.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-export.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-objectmanager-client.c Rework the build system for a new tests approach 2013-05-31 23:12:15 -04:00
gdbus-example-objectmanager-server.c Rework the build system for a new tests approach 2013-05-31 23:12:15 -04:00
gdbus-example-own-name.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-peer.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-proxy-subclass.c Bug 621213 – GDBusProxy and well-known names 2010-06-11 18:21:27 -04:00
gdbus-example-server.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-subtree.c Use 'dumb quotes' rather than `really dumb quotes' 2013-05-21 11:23:22 -03:00
gdbus-example-unix-fd-client.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-watch-name.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-watch-proxy.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-exit-on-close.c tests: port from g_test_trap_subprocess() to g_test_trap_fork() 2013-05-13 12:10:52 -04:00
gdbus-export.c GDBusConnection: be more careful with async GetAll 2013-07-01 23:36:30 -04:00
gdbus-introspection.c tests: move tests to new _get_filename() API 2013-05-29 09:03:32 -04:00
gdbus-message.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-names.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-non-socket.c Use 'dumb quotes' rather than `really dumb quotes' 2013-05-21 11:23:22 -03:00
gdbus-overflow.c Split off the gdbus-overflow test 2013-05-31 21:24:21 -04:00
gdbus-peer-object-manager.c build: Prototype GType accessors for private classes 2012-11-01 20:12:02 -04:00
gdbus-peer.c gcredentials: add internal macros to simplify all the #ifdefs 2013-10-04 09:51:31 -04:00
gdbus-proxy-threads.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-proxy-well-known-name.c tests: move tests to new _get_filename() API 2013-05-29 09:03:32 -04:00
gdbus-proxy.c tests: move tests to new _get_filename() API 2013-05-29 09:03:32 -04:00
gdbus-serialization.c Use 'dumb quotes' rather than `really dumb quotes' 2013-05-21 11:23:22 -03:00
gdbus-sessionbus.c Use GTestDBus in all GDBus unit tests 2012-04-19 10:07:39 +02:00
gdbus-sessionbus.h Use GTestDBus in all GDBus unit tests 2012-04-19 10:07:39 +02:00
gdbus-test-codegen.c Use 'dumb quotes' rather than `really dumb quotes' 2013-05-21 11:23:22 -03:00
gdbus-test-fixture.c Rework the build system for a new tests approach 2013-05-31 23:12:15 -04:00
gdbus-tests.c Use g_timeout_add_seconds for some long timeouts 2013-02-03 10:21:20 -05:00
gdbus-tests.h Use 'dumb quotes' rather than `really dumb quotes' 2013-05-21 11:23:22 -03:00
gdbus-testserver.c Add a C version of gdbus-testserver.py 2013-01-03 13:14:26 -05:00
gdbus-threading.c tests: use new g_test_build_filename() API 2013-05-29 09:03:31 -04:00
gio-du.c More gio-du win32 fixes 2013-09-23 16:31:40 -04:00
gmenumodel.c Improve GMenuModel test coverage 2013-06-02 01:44:15 -04:00
gschema-compile.c GSettings tests: reverse installed test complexity 2013-05-31 23:16:00 -04:00
gsettings.c Improve GSettings test coverage 2013-06-02 20:02:06 -04:00
gsubprocess-testprog.c GSubprocess win32 fixups 2013-10-21 15:24:55 -04:00
gsubprocess.c tests/gsubprocess: Locate test child binary for installed tests too 2013-10-17 22:39:48 +01:00
gtesttlsbackend.c Revert "gtlscertificate: Add certificate-bytes and private-key-bytes props" 2012-08-21 13:30:02 +02:00
gtesttlsbackend.h Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
gtlsconsoleinteraction.c Fix compilation on Android with the bionic C library 2013-04-16 13:24:26 +02:00
gtlsconsoleinteraction.h GTlsDatabase and related objects 2011-08-04 08:54:55 +02:00
httpd.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
inet-address.c gnetworkaddress: allow IPv6 scope ids in URIs 2013-08-19 12:15:36 -04:00
io-stream.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
live-g-file.c live-g-file: test hidden files 2013-03-13 09:41:09 -04:00
live-g-file.txt Revert "Move gio tests from gio/tests/ to tests/gio/" 2009-07-05 22:49:24 -04:00
Makefile.am tests: Add tests for the thumbnail verification code in GIO 2013-10-24 13:55:33 -04:00
memory-input-stream.c Improve GMemoryInputStream test coverage 2013-06-02 01:44:49 -04:00
memory-output-stream.c GMemoryOutputStream: improve seek tests 2013-10-23 11:32:13 -04:00
mimeapps.c Improve GAppInfo test coverage 2013-06-02 01:46:21 -04:00
monitor.c Add a directory monitoring test 2013-06-02 20:02:06 -04:00
network-address.c gio/tests/network-address: fix SCOPE_ID_TEST_INDEX fallback 2013-09-09 23:57:30 +02:00
network-monitor.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
org.gtk.schemasourcecheck.gschema.xml Add test case and fix some bugs 2011-11-17 14:03:39 +00:00
org.gtk.test.dbusappinfo.desktop Make a test desktop file a little less invalid 2013-07-14 11:36:45 -04:00
org.gtk.test.gschema.xml Improve GSettings test coverage 2012-08-19 02:24:04 -04:00
permission.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
pollable.c Fix poll able streams for Darwin (and probably BSD) 2012-11-09 09:23:01 -08:00
proxy-test.c GProxyAddressEnumerator: add default-port property 2013-05-05 16:50:43 -04:00
proxy.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
readwrite.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
resolver.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
resourceplugin.c visibility: Use a separate CFLAGS variable 2013-01-14 23:31:59 -05:00
resources.c tests: move tests to new _get_filename() API 2013-05-29 09:03:32 -04:00
send-data.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
simple-async-result.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
simple-proxy.c GSimpleProxyResolver: new simple GProxyResolver class 2013-02-14 10:24:14 -05:00
sleepy-stream.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
socket-address.c Test GUnixSocketAddress construction 2013-04-23 14:36:07 -04:00
socket-client.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
socket-common.c gio/tests/socket-common.c: add a missing #ifdef G_OS_UNIX 2012-02-03 12:58:53 -05:00
socket-server.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
socket.c gio/tests/socket: fix warning building on win32 2013-08-31 11:40:44 -04:00
srvtarget.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
task.c gio/tests/task: fix a race condition in test_run_in_thread() 2013-08-15 12:43:57 -04:00
test1.txt Add tests for GResource 2012-01-13 17:12:53 +01:00
test2.gresource.xml Add tests for GResource 2012-01-13 17:12:53 +01:00
test2.txt Add tests for GResource 2012-01-13 17:12:53 +01:00
test3.gresource.xml Add tests for GResource 2012-01-13 17:12:53 +01:00
test3.txt Add tests for GResource 2012-01-13 17:12:53 +01:00
test4.gresource.xml Add tests for GResource 2012-01-13 17:12:53 +01:00
test-codegen.xml gdbus-codegen: Update tests for new inheritance-semantics for Since 2012-10-03 11:23:04 -04:00
test-io-stream.c GDBus tests: factor out TestIOStream, test_pipe and test_bidi_pipe 2011-11-21 18:15:26 +00:00
test-io-stream.h GDBus tests: factor out TestIOStream, test_pipe and test_bidi_pipe 2011-11-21 18:15:26 +00:00
test-pipe-unix.c test-pipe-unix: Add missing include 2012-11-02 09:03:52 -04:00
test-pipe-unix.h GDBus tests: factor out TestIOStream, test_pipe and test_bidi_pipe 2011-11-21 18:15:26 +00:00
test.gresource.xml resources: compiler: Allow stripping blanks from xml data 2012-01-25 14:47:37 +01:00
testenum.h Bug 622124 - implement flags for GSettings 2010-07-01 19:06:02 -04:00
thumbnail-verification.c tests: Add tests for the thumbnail verification code in GIO 2013-10-24 13:55:33 -04:00
tls-certificate.c Rename G_TEST_DISTED to G_TEST_DIST 2013-05-29 09:03:32 -04:00
tls-interaction.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
unix-fd.c Add gnetworking.h 2012-12-12 15:20:22 +01:00
unix-streams.c Improve unix stream test coverage 2013-06-02 01:47:19 -04:00
vfs.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
volumemonitor.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
win32-streams.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00