| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
transition. That will come in handy someday.
Allow the server to skip sending a session ticket. GnuTLS seems prone
to offering it even if it doesn't have a key handy.
Fix vector/secure_vector conversions in the SQLite session manager.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
choose_sig_format assumed Client_Hello::supported_algos would always
return something. For SSLv2 hellos, always set it to the default
values. Noticed with OpenSSL 0.9.7m
If a client attempts renegotiation but does not have a secure
renegotiation, only continue if policy allows it. Otherwise send a
no_renegotition alert (what exactly servers are supposed to do is not
really made obvious by the RFC but this seems like reasonable
behavior).
|
| |
|
|
|
|
|
|
|
|
| |
DataSource&.
Remove spurious DataSource_Memory from ec_group.cpp
Some indent fixes
|
|
|
|
| |
attacks and in general detect invalid messages.
|
|
|
|
| |
anymore.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
requirement is that OIDS for "<cipher>/CBC" and "HMAC(<hash>)" are
defined. This does assume the normal parameter set of just the IV, so
doesn't work right for (IIRC) RC5, but we don't have an OID set for
RC5/CBC anyway. Continue to default to SHA-1 plus AES-256 as prior
versions of the library can't handle any hashes other than SHA-1 or
any ciphers other than AES or DES. OpenSSL 1.0.0j seems to understand
SHA-256 + AES-256, though.
BER_Decoder::decode_optional was assuming optional values were
explicitly tagged. Now, only take that behavior if the input class tag
was for a context specific tagging.
Remove abort call for debugging from BER_Decoder
Add a new version of DER_Encoder::encode_if for single objects.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
runs the KDF until at least that much time has passed, then returns
the number of interations used.
New parameter to the PKCS8 encryption routines which tells how long to
run the PBKDF. Defaults to 200 milliseconds, which is short enough
that it is unlikely to bother anyone but long enough to provide quite
reasonable security against cracking attacks. On a Core i7-860, 200
ms with PBKDF2/SHA-1 runs about 180K to 220K iterations (compare with
previous default of 10K).
New PBE interface, remove new_params/set_key and require all inputs
including the passphrase to be passed to the constructor.
Drop the PGP S2K as it is pretty weird and not really useful outside
of a full PGP implementation.
Drop the deprecated PKCS8::encrypt_key and PKCS8::encode functions.
|
| |
|
|
|
|
| |
well together in C++11 mode.
|
| |
|
|
|
|
|
|
| |
only grabbing type 6 (URL) values for OCSP which is likely the only
thing it's ever used for. Expose the value with new function
X509_Certificate::ocsp_responder
|
|
|
|
|
|
| |
Check that whatever certificate we got is allowed to sign OCSP
responses. Add another helper function BER_Decoder to try to handle
the ASN.1 mess.
|
|
|
|
| |
reworking I think, and a lot more testing, but it seems functional.
|
|
|
|
|
|
|
|
| |
In the path validator, pass singlular Certificate_Store args as const
reference and const_cast them. It's not ideal but it seems to lead to
the cleanest external API.
Treat all v1 X.509 certs as implicit CAs.
|
| |
|
|
|
|
|
| |
generate requests and parse replies, does not verify signatures or so
most anything else useful yet.
|
|
|
|
|
|
|
|
|
|
|
|
| |
did it and it would be silly for it not to. Update the two existing
callers, who were both doing start_cons().decode_list().end_cons() to
just call decode_list().
Add BER_Decoder::get_next so we can get arbitrarily weird types
without having to break message chains.
Add dummy tag arguments to the ASN1_Object decoder so it can be used
from decode_optional.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
printer example, and really is just CONSTRUCTED | CONTEXT_SPECIFIC.
Extend the ASN.1 printer to recurse into OCTET STRINGS that
contain DER, and to print enumeration values.
BOTAN_DLL export some OID operators (+, !=, <)
Add an OID entry for 1.3.6.1.5.5.7.48.1.1 OCSP basic response.
Correct the Certificate_Policies code, it was dumping policy OIDs into
the extended key usage!
|
|
|
|
| |
binary) values which we need for OCSP.
|
| |
|
|
|
|
|
|
|
| |
as after all we are reading things that we received over a network
connection so there certainly is no reason to try to mlock them.
Also remove unneeded include in tls_record.h
|
|
|
|
| |
get a secure_vector.
|
|
|
|
|
| |
As best I can tell those are the only Unix kernels that allow
unprivledged users to mlock memory.
|
|
|
|
|
| |
Fix some bugs that triggered if DEFAULT_BUFFERSIZE was either too
small or an odd size.
|
|\
| |
| |
| |
| |
| | |
63b5a20eab129ca13287fda33d2d02eec329708f)
to branch 'net.randombit.botan' (head 8b8150f09c55184f028f2929c4e7f7cd0d46d96e)
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
best_fit->first in cases where we had an almost exact match (exact fit
but with some alignment bytes at the start), meaning that not only
would we lose those bytes forever, but that we might later hand out a
range overlapping with what we handed to our current caller.
Also, in deallocate, lower_bound on the freelist might return end()
(for instance if the freelist is entirely empty). Avoid trying to
update the iterator in that case.
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
were not including it in the header chain. Caused compilation
failures using Clang 3.1 using libc++.
Remove the 3-argument version of hash_seq in SRP6, was not being used.
|
| |
| |
| |
| | |
Plus a few minor cleanups.
|
| |
| |
| |
| |
| |
| | |
We previously ignored a block that was exactly the right size for the
allocation and the needed alignment. If we find such a block prefer it
over any other (non-exact) blocks to minimize fragmentation.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
until we are actually setting a key. This avoids the problem of
prototype objects consuming not just memory but the precious few bytes
of mlock'able memory that we're given by Linux.
Use clear_mem instead of a loop in BigInt::mask_bits
If OS2ECP encounters an invalid format type, include what type it was
in the exception message.
|
| |
| |
| |
| |
| |
| | |
vector of (start,length) where we are careful to maintain the correct
ordering. Much much faster than the map version as it mostly avoids
allocations and copies.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
pointer checks as a sufficiently smart compiler might optimize way
pointer comparisons otherwise. Avoid using an iterator value after we
have released it from the map.
Reduce the default buffer size to 1K to reduce pressure on mlock
memory.
Drop the old mlock wrapper code.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Add a new mlock allocator which is far superior to the previous one
both in terms of behavior (will lock exactly as much memory as we can
actually mlock and will fall back to new/delete in all other cases),
and much better and much simpler freelist than the old mem_pool code.
Currently we only support systems with mmap+mlock, however it should
be easy to extend to also support Windows VirtualLock if desired.
|
| |
| |
| |
| | |
style cast in secmem.h
|
| |
| |
| |
| |
| |
| | |
using a custom allocator. Currently our allocator just does new/delete
with a memset before deletion, and the mmap and mlock allocators have
been removed.
|
| |\
| | |
| | |
| | |
| | |
| | | |
6332543aa5a8a4cc13662008ff9ac0f0016d9a4d)
to branch 'net.randombit.botan.cxx11' (head 5517c9f8f6d1990f269afb94f569a97a80c5a5f4)
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
was not the right size for a signature (following DSA). This would
silently convert to an empty vector which we would treat as a valid
message on the return. However the EMSA checks will always fail so not
a huge problem.
While checking this out I noticed that an empty value for EMSA4 would
result in us reading memory we didn't own.
|
| | |
| | |
| | |
| | |
| | |
| | | |
exceptions thrown in end_msg (for instance in CBC decryption when the
padding is bad) more or less screwed up the pipe completely. Allowing
reset here at least allows an escape hatch.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
-ivb_rdrnd_cpuid option to toggle the bit off and on. Fortunately on
Intel processors the bit we were actually checking is also enabled by
Ivy Bridge. However it is also used on AMD Bulldozer processors to
signal half-precision floating point support so we could false
positive there.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
didn't work on older GCC/binutils. Instead hardcode the expression for
rdrand %eax, which should work everywhere. Also, avoid including immintrin.h
unless we're going to use it, to avoid problems with older compilers that
lack that header (this caused build failures under GCC 3.4.6).
|
| | |
| | |
| | |
| | | |
isn't working here anyway, but also broke DSA servers.
|
| | |
| | |
| | |
| | | |
caused huge performance issues with DSA/ECDSA signing performance.
|