search for: 9a497ed

Displaying 5 results from an estimated 5 matches for "9a497ed".

2017 Feb 16
0
[PATCH v4 1/5] add HIVEX_OPEN_UNSAFE flag.
...ot;created handle %p", h); h->writable = !!(flags & HIVEX_OPEN_WRITE); + h->unsafe = !!(flags & HIVEX_OPEN_UNSAFE); h->filename = strdup (filename); if (h->filename == NULL) goto error; diff --git a/lib/hivex-internal.h b/lib/hivex-internal.h index 26f4964..9a497ed 100644 --- a/lib/hivex-internal.h +++ b/lib/hivex-internal.h @@ -41,6 +41,7 @@ struct hive_h { size_t size; int msglvl; /* 1 = verbose, 2 or 3 = debug */ int writable; + int unsafe; /* Registry file, memory mapped if read-only, or malloc'd if writing. */ unio...
2018 Feb 09
3
[PATCH] Add a cache for iconv_t handles to hive_t
...free (h->filename); + for (int t=0; t<3; t++) { + if (h->iconv_cache[t].handle != NULL) { + iconv_close (h->iconv_cache[t].handle); + h->iconv_cache[t].handle = NULL; + } + } free (h); return r; diff --git a/lib/hivex-internal.h b/lib/hivex-internal.h index 9a497ed..fefdc81 100644 --- a/lib/hivex-internal.h +++ b/lib/hivex-internal.h @@ -23,6 +23,8 @@ #include <stddef.h> #include <string.h> +#include <iconv.h> + #include "byte_conversions.h" #define STREQ(a,b) (strcmp((a),(b)) == 0) @@ -35,6 +37,13 @@ #define STRCASENEQLEN...
2018 Feb 09
0
Re: [PATCH] Add a cache for iconv_t handles to hive_t
...++) { > + if (h->iconv_cache[t].handle != NULL) { > + iconv_close (h->iconv_cache[t].handle); > + h->iconv_cache[t].handle = NULL; > + } > + } > free (h); > > return r; > diff --git a/lib/hivex-internal.h b/lib/hivex-internal.h > index 9a497ed..fefdc81 100644 > --- a/lib/hivex-internal.h > +++ b/lib/hivex-internal.h > @@ -23,6 +23,8 @@ > #include <stddef.h> > #include <string.h> > > +#include <iconv.h> > + > #include "byte_conversions.h" > > #define STREQ(a,b) (strcmp((...
2018 Feb 09
2
[PATCH] Add a cache for iconv_t handles to hive_t
...free (h->filename); + for (int t=0; t<3; t++) { + if (h->iconv_cache[t].handle != NULL) { + iconv_close (h->iconv_cache[t].handle); + h->iconv_cache[t].handle = NULL; + } + } free (h); return r; diff --git a/lib/hivex-internal.h b/lib/hivex-internal.h index 9a497ed..d04ae3c 100644 --- a/lib/hivex-internal.h +++ b/lib/hivex-internal.h @@ -22,6 +22,8 @@ #include <stdarg.h> #include <stddef.h> #include <string.h> +#include <iconv.h> +#include <glthread/lock.h> #include "byte_conversions.h" @@ -35,6 +37,13 @@ #defi...
2017 Feb 16
6
[PATCH v4 0/5] hivex: handle corrupted hives better.
The following patches address issues when dealing with hives that have corrupted data in them but are otherwise readable/writable. Those were found on some rather rare Windows installations that seem to work fine but current hivex fails to even open. Those patches change hivex to simply log and ignore such "corrupted" regions instead of aborting because the caller might be looking at