Hacker News new | ask | show | jobs
by foob 3348 days ago
It's worth mentioning that libfaketime [1] is a more mature alternative with macOS support and more complete coverage of the relevant system calls. Nothing against the current project but that might be a better choice for many people.

[1] - https://github.com/wolfcw/libfaketime

4 comments

Also you can google the name to figure out how to use it.
Libfaketime is great, especially if you have a good idea what time calls your target process is using.

If they're inspecting EHDR and calling VDSO directly, though, or they've statically compiled in their libc, then it won't help though.

I've also had a lot of issues getting it into tightly sandboxed contexts (e.g. the flash runtime in chrome).

I've been a satisfied user of libfaketime as well. Would be great if the OP could highlight the feature differences to it!
Sadly, the license is GPL rather than the expected LGPL.
In what sense LGPL is "expected"?
For a lib
This library is not meant to be incorporated into an application - it is meant to be preloaded to modify the behaviour of an existing program. So I don't see what permission to link into a proprietary program really gets you.