Hi,

tinyca hangs due to a regression in openssl, fixed in:

    
https://github.com/openssl/openssl/commit/888adbe064556ff5ab2f1d16a223b0548696614c

The tinyca code quality is still very low - very close to unacceptable
for something handling private keys and crypto.

* it builds strings to execute with /bin/sh -c "...", and quotes 
  filenames using \"$filename\" in perl.  It should pass the command
  and arguments as list instead - it's not that complicated.
* trying to respond to the openssl interactive mode seems a very bad
  idea.
* when I close tinyca (working on an existing setup) perl crashes with 
  a segfault (no idea who to blame for this, see attached 
  tinyca-perl-valgrind.txt)

cheers,
Stefan
==28880== Invalid read of size 8
==28880==    at 0x68C9678: ??? (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2BDB: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB4CEA5F: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68DF3EF: g_value_unset (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2C11: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB5C74F4: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x666EF99: ??? (in 
/usr/lib/x86_64-linux-gnu/perl5/5.24/auto/Glib/Glib.so)
==28880==    by 0x1DC0BF: Perl_pp_entersub (in /usr/bin/perl)
==28880==  Address 0xffeffebc8 is on thread 1's stack
==28880==  2280 bytes below stack pointer
==28880== 
==28880== Invalid read of size 8
==28880==    at 0x68C9670: ??? (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2BDB: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB4CEA5F: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68DF3EF: g_value_unset (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2C11: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB5C74F4: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x666EF99: ??? (in 
/usr/lib/x86_64-linux-gnu/perl5/5.24/auto/Glib/Glib.so)
==28880==    by 0x1DC0BF: Perl_pp_entersub (in /usr/bin/perl)
==28880==  Address 0xffeffebc0 is on thread 1's stack
==28880==  2288 bytes below stack pointer
==28880== 
==28880== Conditional jump or move depends on uninitialised value(s)
==28880==    at 0x68C967C: ??? (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2BDB: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB4CEA5F: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68DF3EF: g_value_unset (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2C11: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB5C74F4: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x666EF99: ??? (in 
/usr/lib/x86_64-linux-gnu/perl5/5.24/auto/Glib/Glib.so)
==28880==    by 0x1DC0BF: Perl_pp_entersub (in /usr/bin/perl)
==28880== 
==28880== Conditional jump or move depends on uninitialised value(s)
==28880==    at 0x68C9676: ??? (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2BDB: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB4CEA5F: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68DF3EF: g_value_unset (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2C11: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB5C74F4: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x666EF99: ??? (in 
/usr/lib/x86_64-linux-gnu/perl5/5.24/auto/Glib/Glib.so)
==28880==    by 0x1DC0BF: Perl_pp_entersub (in /usr/bin/perl)
==28880== 
==28880== Use of uninitialised value of size 8
==28880==    at 0x68C9678: ??? (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2BDB: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB4CEA5F: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68DF3EF: g_value_unset (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2C11: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB5C74F4: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x666EF99: ??? (in 
/usr/lib/x86_64-linux-gnu/perl5/5.24/auto/Glib/Glib.so)
==28880==    by 0x1DC0BF: Perl_pp_entersub (in /usr/bin/perl)
==28880== 
==28880== 
==28880== Process terminating with default action of signal 11 (SIGSEGV)
==28880==  Access not within mapped region at address 0x18
==28880==    at 0x68C9678: ??? (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2BDB: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB4CEA5F: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68DF3EF: g_value_unset (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2C11: g_signal_emit_valist (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x68D2FBE: g_signal_emit (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0xB5C74F4: ??? (in 
/usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0.2400.31)
==28880==    by 0x68BCC04: g_object_unref (in 
/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.5000.3)
==28880==    by 0x666EF99: ??? (in 
/usr/lib/x86_64-linux-gnu/perl5/5.24/auto/Glib/Glib.so)
==28880==    by 0x1DC0BF: Perl_pp_entersub (in /usr/bin/perl)
==28880==  If you believe this happened as a result of a stack
==28880==  overflow in your program's main thread (unlikely but
==28880==  possible), you can try to increase the size of the
==28880==  main thread stack using the --main-stacksize= flag.
==28880==  The main thread stack size used in this run was 8388608.
==28880== 
==28880== HEAP SUMMARY:
==28880==     in use at exit: 17,297,153 bytes in 93,497 blocks
==28880==   total heap usage: 284,257 allocs, 190,760 frees, 35,891,579 bytes 
allocated
==28880== 
==28880== LEAK SUMMARY:
==28880==    definitely lost: 8,808 bytes in 72 blocks
==28880==    indirectly lost: 17,354 bytes in 661 blocks
==28880==      possibly lost: 8,025,407 bytes in 17,443 blocks
==28880==    still reachable: 8,944,152 bytes in 73,427 blocks
==28880==                       of which reachable via heuristic:
==28880==                         length64           : 14,256 bytes in 183 
blocks
==28880==                         newarray           : 116,648 bytes in 3,430 
blocks
==28880==         suppressed: 0 bytes in 0 blocks
==28880== Rerun with --leak-check=full to see details of leaked memory
==28880== 
==28880== For counts of detected and suppressed errors, rerun with: -v
==28880== Use --track-origins=yes to see where uninitialised values come from
==28880== ERROR SUMMARY: 8 errors from 5 contexts (suppressed: 0 from 0)

Reply via email to