bindp libindp.so C code fixes

Information

ID: 599
PHID: PHID-TASK-jwbjbkgnxkowp7oe2wvr
Author: Patrick
Status at Migration Time: resolved
Priority at Migration Time: Normal

Description

Whonix forked bindp. Was required for #uwt (T561) (bindp.c).


Compilation:
gcc -nostartfiles -fpic -shared bindp.c -o libindp.so -ldl -D_GNU_SOURCE -D_FORTIFY_SOURCE=2 -g -O2 -fPIE -fstack-protector-strong -Wformat -Werror=format-security -fPIE -pie -Wl,-z,relro -Wl,-z,now


TODO:

  • check and fix

! In T561#11378, @marmarek wrote:
The only issue I see is it replace address in all bind calls - even those with different address family than AF_INET. In that case, address structure may be different (and also have different size) and strange things may happen. If a particular application use only AF_INET binds, it should be ok. You can check with strace and grep.




/path/to/checksec.sh --file /path/to/libindp.so
RELRO           STACK CANARY      NX            PIE             RPATH      RUNPATH      FILE
Full RELRO      No canary found   NX enabled    PIE enabled     No RPATH   No RUNPATH   libindp.so

This ticket is based on @marmarek’s feedback in T561#11378.

Comments


s.sh

2017-02-22 08:41:46 UTC


Patrick

2017-02-22 09:07:19 UTC


s.sh

2017-02-22 10:12:25 UTC


s.sh

2017-02-22 10:28:54 UTC


Patrick

2017-02-22 13:29:03 UTC


s.sh

2017-02-22 14:06:53 UTC


Patrick

2017-02-23 00:28:23 UTC


marmarek

2017-02-23 01:03:37 UTC


s.sh

2017-03-05 21:26:02 UTC


marmarek

2017-03-05 21:34:14 UTC


s.sh

2017-03-06 18:16:47 UTC


Patrick

2017-03-06 18:48:16 UTC


s.sh

2017-03-06 18:56:51 UTC


Patrick

2017-03-06 19:24:37 UTC


Patrick

2017-03-06 19:38:53 UTC


s.sh

2017-03-06 19:41:55 UTC


Patrick

2017-03-06 19:46:44 UTC


s.sh

2017-03-06 20:03:00 UTC


Patrick

2017-03-06 20:27:11 UTC


s.sh

2017-03-06 20:36:44 UTC


s.sh

2017-03-06 20:48:49 UTC


s.sh

2017-03-07 13:26:20 UTC


Patrick

2017-03-07 15:55:00 UTC


s.sh

2017-03-07 19:14:27 UTC


Patrick

2017-03-07 21:35:44 UTC


Patrick

2017-03-07 21:51:24 UTC


Patrick

2017-03-07 21:58:44 UTC


Patrick

2017-03-07 22:00:34 UTC


s.sh

2017-03-08 06:22:46 UTC


Patrick

2017-03-08 14:54:28 UTC


s.sh

2017-03-08 18:27:53 UTC


s.sh

2017-03-08 19:37:16 UTC


Patrick

2017-03-08 21:48:17 UTC


s.sh

2017-03-08 22:05:01 UTC


Patrick

2017-03-08 22:40:31 UTC


s.sh

2017-03-09 15:58:45 UTC


Patrick

2017-03-09 16:40:08 UTC


s.sh

2017-03-09 16:50:24 UTC


Patrick

2017-03-09 18:19:03 UTC


Patrick

2017-03-09 18:35:46 UTC


s.sh

2017-03-10 11:51:17 UTC


Patrick

2017-03-26 11:53:36 UTC


Patrick

2017-03-26 11:53:41 UTC


Patrick

2017-06-16 15:41:23 UTC


s.sh

2017-06-16 16:15:35 UTC


Patrick

2017-06-16 17:01:04 UTC


s.sh

2017-06-16 17:47:10 UTC


Patrick

2017-06-16 18:16:56 UTC


s.sh

2017-06-16 18:21:09 UTC


Patrick

2017-07-03 11:52:48 UTC


s.sh

2017-07-03 18:54:58 UTC