Package: file Version: 1:5.34-2 Severity: normal I found the file(1) tool on Debian buster would erroneously detect ELF shared libraries as 'pie executable'; for example:
~/src$ cat sample.c #include <stdio.h> void func1(int a) { fprintf(stderr, "function: func1(%d)\n", a); } ~/src$ gcc -Wall -O1 --shared sample.c -o libsample.so ~/src$ file libsample.so libsample.so: ELF 32-bit LSB pie executable, Intel 80386, version 1 (SYSV), dynamically linked, BuildID[sha1]=56c53c1ca858c31c2d58bf9ee80e3eb9ff4ac36d, not stripped -- System Information: Debian Release: buster/sid APT prefers testing APT policy: (500, 'testing') Architecture: i386 (x86_64) Kernel: Linux 4.4.0-124-generic (SMP w/8 CPU cores) Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968), LANGUAGE=C (charmap=ANSI_X3.4-1968) Shell: /bin/sh linked to /bin/dash Init: unable to detect Versions of packages file depends on: ii libc6 2.27-5 ii libmagic1 1:5.34-2 ii zlib1g 1:1.2.11.dfsg-1 file recommends no packages. file suggests no packages. -- no debconf information