This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA] Add --enable-codesign to gdb's configure


> I'm not sure there's a way for gdb to know whether it's been signed, I
> guess other than invoking codesign itself.  I'm going to check this in,
> but if it still needs the change, let me know and I will see if I can
> implement it.

I just gave it a try, and basically, you do it using the -d option
of codesign. I also added -v, to get a bit more information about
the signature -- otherwise, you either get "not signed", or the name
of the executable. Here is an example of both situations:

  | $ codesign -dv simple_main
  | simple_main: code object is not signed at all
  | $ codesign -dv gdb
  | Executable=/[...]/gdb
  | Identifier=org.gnu.gdb
  | Format=Mach-O thin (x86_64)
  | CodeDirectory v=20100 size=82012 flags=0x0(none) hashes=2559+2 location=embedded
  | Signature size=1572
  | Signed Time=23 Feb 2017 09:29:17
  | [...]

-- 
Joel


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]