add "generic" format string based encoder and decoder (scan_asn1generic,

fmt_asn1generic, see t10.c for example usage)
add "generic" asn.1 dumper (in t10.c)
fix some read off-by-one errors, minor cleanups
add real OID support
add bitstring support
This commit is contained in:
leitner
2011-04-28 19:50:11 +00:00
parent e90320f819
commit e04ca78ff8
49 changed files with 483 additions and 110 deletions

6
acl.c
View File

@@ -1,6 +1,7 @@
#define _FILE_OFFSET_BITS 64
#define MAIN
#include "ldap.h"
#include <buffer.h>
#include <stralloc.h>
#include <str.h>
@@ -11,7 +12,6 @@
#include <byte.h>
#include <mmap.h>
#include <case.h>
#include <ldap.h>
#include <uint16.h>
#include <uint32.h>
#include <open.h>
@@ -275,7 +275,7 @@ int marshalfilter(stralloc* x,struct assertion* a) {
int marshal(char* map,size_t filelen,const char* filename) {
size_t filters,acls,i,j,k;
size_t filter_offset,acl_offset;
size_t filter_offset; //,acl_offset;
struct acl* a;
uint32* F,* A;
uint32 attribute_count;
@@ -396,7 +396,7 @@ nomem:
A=malloc(sizeof(*A)*acls);
if (!A) goto nomem;
acl_offset=F[i]+(acls+1)*sizeof(*A);
// acl_offset=F[i]+(acls+1)*sizeof(*A);
i=0;
for (a=root; a; a=a->next) {