Commit Graph

460 Commits

Author SHA1 Message Date
Hallvard Furuseth
e1d42189fa ITS#4990: Fix LDAP_MEMORY_DEBUG and LDAP_MEMORY_DEBUG=0 compilation.
Declare ber_int_meminuse.  Fix '#if' -> '#ifdef' LDAP_MEMORY_DEBUG.
2007-07-04 22:55:24 +00:00
Hallvard Furuseth
bfdb026fab ITS#5007: Remove void* pointer arithmetic, that's a gcc extension. 2007-06-09 23:41:36 +00:00
Hallvard Furuseth
3750520f6f Fix HP-UX crash: Replace socklen_t with ber_socklen_t from configure. ITS#4629. 2007-06-09 23:35:20 +00:00
Hallvard Furuseth
bbc719ca56 ITS#4948: '#if <undefined macro>' -> '#ifdef' warning cleanup 2007-05-09 18:17:10 +00:00
Hallvard Furuseth
545b5555fb ber_decode_oid(), ber_encode_oid(): cast bv_val to unsigned char* 2007-04-04 17:51:10 +00:00
Howard Chu
c6df30118f ITS#4893 fix prev commit 2007-03-25 12:18:06 +00:00
Howard Chu
7426ab07fc ITS#4893 define LDAP_PF_LOCAL_SENDMSG in <ac/socket.h> if a message must
be sent to transmit client credentials. Buffer the message data.
2007-03-25 04:40:22 +00:00
Howard Chu
724784e6cb Use AC_MEMCPY 2007-03-25 04:31:34 +00:00
Howard Chu
b213588f95 Add options for ber_get_stringbv() to omit NUL-terminator, to allow
non-destructive in-place parsing
2007-03-23 15:27:38 +00:00
Howard Chu
9fe8f72310 Add DER OID encoder/decoder 2007-03-20 15:10:16 +00:00
Howard Chu
23ba7dfa12 Add ber_skip_data() to help positioning in structured BER data 2007-03-20 12:29:06 +00:00
Howard Chu
e0ed944be3 Added ber_bvarray_dup_x() 2007-02-05 04:31:38 +00:00
Kurt Zeilenga
da6d9eb046 happy new year 2007-01-02 20:00:42 +00:00
Howard Chu
57c329a3af ITS#4606 errno is not per-thread on WIN32, always use WSAGet/SetLastError
(with notable exceptions: ignore tests for EINTR which winsock never sets)
2006-09-14 06:35:34 +00:00
Pierangelo Masarati
8f1c5c4df5 improve previous commit 2006-06-15 01:47:39 +00:00
Pierangelo Masarati
8b76e15d28 fix ber_bvreplace() in case dst is NULL and src is empty 2006-06-15 01:42:25 +00:00
Hallvard Furuseth
02bb67044b Cleanup since last patch (remove unused label) 2006-04-13 22:13:42 +00:00
Pierangelo Masarati
dfc8e7f6b8 better fix for ITS#4483 2006-04-09 22:29:42 +00:00
Pierangelo Masarati
23c620a637 don't leak a BerElement 2006-04-08 17:34:00 +00:00
Kurt Zeilenga
cbc11c9233 unifdef -DLDAP_NULL_IS_NULL 2006-02-14 23:18:12 +00:00
Kurt Zeilenga
acbb5cf689 Happy new year! 2006-01-03 23:11:52 +00:00
Pierangelo Masarati
eb734a167b add severity-aware logging (ITS#4282) 2005-12-27 16:29:37 +00:00
Pierangelo Masarati
4a6f4369c0 don't malloc empty strings for matched, error 2005-11-12 18:42:03 +00:00
Howard Chu
10c94f4e58 Cleanup lbo_valid / meminuse / memfuncs 2005-11-12 18:26:17 +00:00
Howard Chu
0f9ad702c3 ITS#4046 fix recvfrom len 2005-09-28 08:36:24 +00:00
Howard Chu
2807a2596b Simplify array operations 2005-09-13 07:51:51 +00:00
Pierangelo Masarati
9129a2f7ee silence warnings 2005-09-10 18:59:35 +00:00
Hallvard Furuseth
d47eaa0ecc Fix printf formats for LDAP_MEMORY_TRACE 2005-08-02 14:08:30 +00:00
Hallvard Furuseth
5c5a834db8 Handle LBER_SB_OPT_[GS]ET_FD arg as ber_socket_t like elsewhere, not as int. 2005-08-01 03:48:53 +00:00
Pierangelo Masarati
aa0b0f642f don't malloc when not required? 2005-07-21 19:10:16 +00:00
Pierangelo Masarati
1b11741a30 mostly revert previous commit 2005-07-20 19:26:46 +00:00
Pierangelo Masarati
c789d494c4 allow to unregister (and free) memory handling functions 2005-07-20 19:07:04 +00:00
Hallvard Furuseth
81ecb0b153 assert expects int. (int)<nonnull ptr/long> can be 0. Use assert(arg!=0/NULL). 2005-07-18 06:22:33 +00:00
Pierangelo Masarati
12c32c3e6c fix previous commit 2005-04-27 02:38:55 +00:00
Pierangelo Masarati
2f877b48b1 introduce ber_bvreplace() 2005-04-21 03:40:50 +00:00
Kurt Zeilenga
dc0eacd40b Happy New Year! 2005-01-01 20:49:32 +00:00
Kurt Zeilenga
e983616d75 More NEW_LOGGING removal 2004-10-19 01:40:38 +00:00
Kurt Zeilenga
d611a4b49a unifdef -UNEW_LOGGING 2004-09-04 04:54:28 +00:00
Kurt Zeilenga
e0a9ea2f50 Move MSVC port to the Attic 2004-09-04 04:37:41 +00:00
Howard Chu
24b7f5c42c Fix 't' tag option 2004-07-09 10:19:20 +00:00
Kurt Zeilenga
93b72e36e8 cleanup 2004-06-30 22:28:15 +00:00
Kurt Zeilenga
781c2d02a1 fix Compare bug in liblber/memory.c (ITS#3116) 2004-04-26 23:16:45 +00:00
Kurt Zeilenga
62da0b6738 AC_STRERROR_R 2004-04-25 00:19:06 +00:00
Howard Chu
affe835984 NUL-terminate alloc'd berbuf (ITS#3086) 2004-04-15 10:25:14 +00:00
Kurt Zeilenga
b3fdf881c3 ITS#3072: remove extraneous assignment 2004-04-08 20:20:36 +00:00
Howard Chu
c558bd49bc ITS#2992 Windows fixes from Alexey Melnikov 2004-03-05 12:24:06 +00:00
Howard Chu
f8d54b4e87 Fix prev EBCDIC commit 2004-02-04 22:53:17 +00:00
Howard Chu
9f3b0d60f9 Fix EBCDIC conversion for syslog() 2004-02-03 03:58:38 +00:00
Kurt Zeilenga
3c598e89fb Happy new year 2004-01-01 19:15:16 +00:00
Kurt Zeilenga
c5f83acf6e cleanup 2003-12-07 05:12:36 +00:00
Howard Chu
f01c60dd66 ITS#2538 plug leak 2003-12-07 04:48:50 +00:00
Kurt Zeilenga
85013a9d98 acknowledgements and notices 2003-11-26 22:51:15 +00:00
Kurt Zeilenga
159de0f135 Updated notices and acknowledgements 2003-11-26 07:16:36 +00:00
Kurt Zeilenga
e3a4c4ec9c Notice/Acknowledge updates 2003-11-26 02:58:56 +00:00
Kurt Zeilenga
327880b984 Notice updates 2003-11-25 23:17:08 +00:00
Howard Chu
ede6ea1f64 Fix typo in LTFINISH invcation 2003-10-01 02:26:41 +00:00
Kurt Zeilenga
db097047af code cleanup 2003-07-08 03:46:20 +00:00
Hallvard Furuseth
a231098e28 Fix typo in comment 2003-06-27 19:12:07 +00:00
Hallvard Furuseth
0f29f0af96 #define *_OPT_ON &ber_pvt_opt_on. The old (void*)1 definition could be == NULL. 2003-06-06 13:50:01 +00:00
Hallvard Furuseth
1fa40181d9 Cast unsigned char *p to char *. 2003-06-03 17:51:38 +00:00
Howard Chu
a3b73b50ce Fix includes for EBCDIC 2003-05-29 10:02:10 +00:00
Howard Chu
5d0ba372e5 Fix LBER_OPT_MEMCTX behavior 2003-05-28 22:17:08 +00:00
Howard Chu
13aa48e47a Fix reading multibyte lengths 2003-05-22 06:24:23 +00:00
Kurt Zeilenga
71e0359f37 Back out last change... I forget ber_get_next eats a sequence 2003-05-22 05:41:13 +00:00
Kurt Zeilenga
6035ecfe7b Reverse unintended commit 2003-05-22 05:33:04 +00:00
Kurt Zeilenga
df1381fa38 cleanup 2003-05-22 05:32:06 +00:00
Kurt Zeilenga
a08e72a9e8 Remove wrapping sequence to align with dtest 2003-05-22 04:45:50 +00:00
Kurt Zeilenga
6d36ba9d9f Add trickle code to test ber_get_next.
Use etest {...} | dtest {...} to test.
2003-05-22 04:37:44 +00:00
Kurt Zeilenga
bfa6808c48 Fix dtest ber_get_next() usage 2003-05-22 03:35:36 +00:00
Howard Chu
3d9fd17678 ber_get_next - set errno to 0 before calling ber_int_sb_read(), otherwise
an EOF will return with the previously set errno value.
2003-05-20 04:08:35 +00:00
Jong Hyuk Choi
4f58efc4d1 - change in message to modlist conversion 2003-05-20 01:45:12 +00:00
Howard Chu
3fc96a24ee More ITS#2490 - fix retries for multi-byte lengths 2003-05-19 12:14:15 +00:00
Howard Chu
5eb0ec070c ITS#2490 - more retry checks 2003-05-19 10:37:09 +00:00
Howard Chu
9757665aed ITS#2490 - allow retry for incomplete reads of BER tag & len 2003-05-19 10:33:18 +00:00
Hallvard Furuseth
5ee9264465 Fix assignment of <char/int>* to unsigned <char/int>* and vice versa. 2003-05-02 13:29:28 +00:00
Howard Chu
23b63aac39 Free ber mem arrays in reverse order. (better for sl_free) 2003-04-29 21:09:02 +00:00
Hallvard Furuseth
778a38f49c Reduce warnings: Add missing 0 or NULL initializers for struct members. 2003-04-29 16:36:19 +00:00
Howard Chu
deea8db4cd EBCDIC fix - ber_pvt_strcopy is now lutil_strcopy 2003-04-25 12:32:15 +00:00
Howard Chu
a413bab19a Clean up prev commit 2003-04-24 04:20:17 +00:00
Howard Chu
b6111d793e Fix multi-byte tag parsing 2003-04-24 03:59:45 +00:00
Howard Chu
bcf7ab26e4 ITS#2465 fix? ber_get_next must read at least sizeof(tag)+sizeof(len)
which should be at most 8 bytes. However if we read more than the minimum
message length, we have a problem because we steal bytes from any following
message, and there is no buffer mechanism to push back excess data.
The shortest legitimate message is Unbind at 7 bytes, but there shouldn't
be anything following it. Abandon at 8 bytes is next, so always requesting
at least 8 bytes should be safe. Always requesting 9 was a problem.

Please double-check these assumptions...
2003-04-24 02:10:18 +00:00
Howard Chu
d14ff18d7f ITS#2458 fix array decoding 2003-04-24 01:37:01 +00:00
Howard Chu
42e7845d81 More malloc context tweaks 2003-04-10 06:14:16 +00:00
Howard Chu
ca12bb75c7 Extended API for ber_mem functions, add context argument.
Must always use ber_mem funcs, even if CSRIMALLOC is present.
2003-04-09 13:25:11 +00:00
Howard Chu
e240135305 ITS#2434 ber accessors 2003-04-09 09:41:02 +00:00
Kurt Zeilenga
e41ca42de1 mark a few translatable strings 2003-04-06 06:19:13 +00:00
Kurt Zeilenga
1b37568b00 Use ifdef not comment to comment out code 2003-03-22 22:28:57 +00:00
Howard Chu
8a8ae8bf85 Add comment to previous 2003-03-12 03:23:09 +00:00
Howard Chu
066e3310a9 ITS#2365 - preserve internal ber_tag as well as ber_ptr for rewinding. 2003-03-12 02:33:53 +00:00
Pierangelo Masarati
e24f55b29a silence warning 2003-03-04 09:16:57 +00:00
Howard Chu
50ecec94eb Fix ITS#2344, prev commit changed too much. 2003-03-03 23:44:22 +00:00
Howard Chu
3cc07977fa Replace recursive get_stringbvr with iterative get_stringbvl to avoid
stack overrun when parsing large groups
2003-03-03 15:54:49 +00:00
Howard Chu
ec497cf529 Use fixed sizes for ber_get_next to avoid 64-bit hangs. 2003-03-02 04:02:39 +00:00
Kurt Zeilenga
aa291a3492 We should be calling libtool --finish when install libraries 2003-02-09 23:10:29 +00:00
Howard Chu
5354dbf269 ber_flush shouldn't be logging with _ANY, changed to _TRACE 2003-01-31 22:45:19 +00:00
Howard Chu
60d621fc04 Fix typo 2003-01-23 03:35:31 +00:00
Howard Chu
caeb6fc1f0 Fix ITS#2280, reject sequences with invalid lengths 2003-01-23 02:19:59 +00:00
Kurt Zeilenga
bd9bf709aa ITS#2275: PROTOS ber_get_next() fix
Needs review!!!!
2003-01-22 22:29:11 +00:00
Hallvard Furuseth
f963a16150 Remove an implicit int, to silence gcc warnings. 2003-01-19 14:03:11 +00:00
Hallvard Furuseth
9d11c5ea46 Remove pointless `unsigned < 0' test. 2003-01-19 14:02:06 +00:00