[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #27802 [Core Tor/Tor]: OpenSSL 1.1.0 issue during static link
#27802: OpenSSL 1.1.0 issue during static link
-------------------------------------------------+-------------------------
Reporter: cretz | Owner: (none)
Type: defect | Status: new
Priority: Medium | Milestone: Tor:
| 0.4.2.x-final
Component: Core Tor/Tor | Version:
Severity: Normal | Resolution:
Keywords: static, 029-backport, 032 | Actual Points:
-unreached-backport, 033-unreached-backport |
042-can? |
Parent ID: #6623 | Points:
Reviewer: | Sponsor:
-------------------------------------------------+-------------------------
Comment (by str4d):
Compiling and running the above failed program in GDB, I get:
{{{
$ gcc -m64 -o conftest -pipe -O1 -static -I/path/to/include
-L/path/to/lib conftest.c -lssl -lcrypto -lpthread -ldl
/path/to/lib/libcrypto.a(b_addr.o): In function `BIO_lookup_ex':
b_addr.c:(.text+0xc73): warning: Using 'getaddrinfo' in statically linked
applications requires at runtime the shared libraries from the glibc
version used for linking
/path/to/lib/libcrypto.a(b_sock.o): In function `BIO_gethostbyname':
b_sock.c:(.text+0x69): warning: Using 'gethostbyname' in statically linked
applications requires at runtime the shared libraries from the glibc
version used for linking
$ gdb conftest
GNU gdb (Ubuntu 8.1-0ubuntu3.1) 8.1.0.20180409-git
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
warning: ~/.gdbinit.local-pre: No such file or directory
/home/str4d/.gdbinit:80: Error in sourced command file:
t SW:2600: Error in sourced command file:
Undefined command: "SW". Try "help".
Reading symbols from conftest...done.
gdb$ r
Starting program: /home/str4d/dev/git/tor/tmp/conftest
Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
gdb$ bt
#0 0x0000000000000000 in ?? ()
#1 0x00000000004f9e55 in __register_frame_info_bases.part.6 ()
#2 0x0000000000400c5d in frame_dummy ()
#3 0x0000000000000001 in ?? ()
#4 0x00000000004fb0cc in __libc_csu_init ()
#5 0x00000000004fa897 in __libc_start_main ()
#6 0x0000000000400b7a in _start ()
}}}
If I remove the `-static` flag, the program successfully runs.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/27802#comment:12>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs