Vector35 / Vector35/binaryninja-api
Improve *OS type libraries
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 1.3k
- Forks
- 298
- Avg merge
- 5d 5h
- Merged PRs (30d)
- 19
Description
Following up with #2735 "early" resolution, I'd like Vector35 to consider bringing more love to *OS types in embedded type libraries or, alternatively, I could dig a reliable solution to get there "automagically".
Basically, I'd like to no longer have to import standard C types a target would need like this:
The type library would contains at least platform SDK includes that are stable enough, ex: curl/curl.h, unistd.h, etc.
I'd also expect such a library — or tool — to handle #define'd constants. For example, this:
#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
#define _CS_DARWIN_USER_DIR 65536
#define _CS_DARWIN_USER_TEMP_DIR 65537
#define _CS_DARWIN_USER_CACHE_DIR 65538
#endif /* __DARWIN_C_LEVEL >= __DARWIN_C_FULL */
Would become a "Binary Ninja enumerations" like that:
#pragma mark - unistd.h
// confstr(3)
enum conf_vars: int {
_CS_DARWIN_USER_DIR = 65536,
_CS_DARWIN_USER_TEMP_DIR = 65537,
_CS_DARWIN_USER_CACHE_DIR = 65538,
};
And while we are here, I would be thrilled to also have open-source C and C++ types for *OS, like CommonCrypto/CommonCrypto.h, and SDK headers from Foundation / CoreFoundation, IOKit, etc..
That would be neat.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Read #2735 first, then compare the embedded type-library request with the named headers curl/curl.h, unistd.h, and Apple SDK headers. Done means defining an implementation path for *OS libraries that also represents the requested #define constants and C/C++ types; the issue names no files or tests to run.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, cpp
- Domain
- reverse-engineering
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100