Age | Commit message (Collapse) | Author |
|
|
|
|
|
While not the greatest of names, ecp_methods.c is better than ecp_smpl.c.
It matches the naming ecx_methods.c and in a subsequent commit it will
become the new home of the stuff in ecp_mont.c as well.
discussed with jsing
|
|
Apparently it's important that five trivial one-line wrappers remain in a
file with the ISC license. So instead of cleaning the root directory of our
favorite pigsty further by squashing all the useless legacy garbage into a
single file, rename the oddly-named malloc-wrapper.c into crypto_memory.c.
discussed with beck, jsing
|
|
It is a bit sad, because cpt is such an apt abbreviation for crypto that
everybody immediately understands.
discussed with jsing
|
|
discussed with jsing
|
|
discussed with jsing
|
|
The correct spelling is explicit_bzero() and it doesn't need its own file.
discussed with jsing
|
|
discussed with jsing
|
|
discussed with jsing
|
|
The reason these were in separate files was FIPS. Not our problem.
|
|
|
|
discussed with jsing
|
|
discussed with jsing
|
|
EC_GROUP_check() is quite simple. It doesn't need to use its own file.
|
|
This used to be a trivial wrapper of the ASN1_add_oid_module() horror.
It's no longer exported, so it can go away. It moves from the terribly
named file conf_mall.c to the equally terribly named file conf_sap.c.
I have no idea what mall and sap are supposed to mean in this context.
|
|
Another single-function file goes away.
|
|
Discussed with tb@
|
|
There is no need for these to be separate (presumably done due to assembly
implementations, even though there are #ifdef as well).
Discussed with tb@
|
|
This allows us in particular to get rid of the MD Symbols.list which
were needed on amd64 and i386 for llvm 16 a while back. OPENSSL_ia32cap_P
was never properly exported since the symbols were marked .hidden in the
asm.
ok beck jsing
|
|
It's just gross. Only used by a popular disk encryption utility on an
all-too-popular OS one or two decades back.
ok beck jsing
|
|
Unfortunately we'll probably never be able to get rid of DES entirely.
One part of it that is old enough to be a grandparent can go, though.
ok beck jsing
|
|
ok beck jsing
|
|
This makes the _CONF_* layer of the conf module internal and gets rid
of the entirely unused conf_api.h.
ok beck jsing
|
|
Much of conf is designed in such a way that you really have to reach into
its structs. This one piece can be hidden. It might even be removed soon.
ok beck jsing
|
|
This is a slightly strange combination of OBJ_find_sigid_algs() and the
security level API necessary because OBJ_find_sigid_algs() on its own
isn't smart enough for the special needs of RSA-PSS and EdDSA.
The API extracts the hash's NID and the pubkey's NID from the certificate's
signatureAlgorithm and invokes special handlers for RSA-PSS and EdDSA
for retrieving the corresponding information. This isn't entirely free
for RSA-PSS, but for now we don't cache this information.
The security bits calculation is a bit hand-wavy, but that's something
that comes along with this sort of numerology.
ok jsing
|
|
unused in ports and on codesearch
|
|
CRYPTO_EX_DATA exists as a way to allow an application to attach data to
various components in libcrypto and libssl. The general idea is that there
are various "classes" (e.g. RSA) and an application can get an "index"
(which can have new/dup/free functions provided). The application can then
use the index to store a pointer to some form of data within that class,
for later retrieval.
However, even by OpenSSL standards, this is an insane API. The current
implementation allows for data to be set without calling new, indexes
can be used without allocation, new can be called without actually getting
an index and dup can be called either after new or without new (see regress
and RSA_get_ex_new_index(3)/CRYPTO_set_ex_data(3) for more details). On
top of this, the previous "overhaul" of the code was written to be
infinitely extensible.
For now, the rewrite intends to maintain the existing behaviour - once we
bed this down we can attempt to ratchet the API requirements and require
some sort of sensible sequence. The only intentional change is that there
is now a hard limit on the number of indexes that can be allocated
(previously there was none, relying only on ENOMEM).
ok tb@
|
|
symbols from symbols.list now that we have everything hidden
ok tb@
|
|
ok jsing
|
|
(instead of commiting only one part)
|
|
Some further refinements will happen to the build process to
automatically generate the Symbols.namespace file, and to remove
our last public unhidden symbol (which was a mistake, but waits for
a major bump to get removed)
But for now everything should be using this.
ok tb@
|
|
These constitute the bulk of the remaining global mutable state in
libcrypto. This commit moves most of them into data.rel.ro, leaving
out ERR_str_{functs,libraries,reasons} (which require a slightly
different approach) and SYS_str_reasons which is populated on startup.
The main observation is that if ERR_load_strings() is called with a 0 lib
argument, the ERR_STRING_DATA argument is not actually modified. We could
use this fact to cast away const on the caller side and be done with it.
We can make this cleaner by adding a helper ERR_load_const_strings() which
explicitly avoids the assignment to str->error overriding the error code
already set in the table.
In order for this to work, we need to sprinkle some const in err/err.c.
CMS called ERR_load_strings() with non-0 lib argument, but this didn't
actually modify the error data since it ored in the value already stored
in the table.
Annoyingly, we need to cast const away once, namely in the call to
lh_insert() in int_err_set_item(). Fixing this would require changing
the public API and is going to be tricky since it requires that the
LHASH_DOALL_FN_* types adjust.
ok jsing
|
|
The most terrible code in OpenSSL has its roots in libdes, which came
before SSLeay. Hello, LHASH. Hello speed app. Hello DES (obviously).
There are some diary-style changelog comments dating all the way back
to 1990.
/* This has some uglies in it but it works - even over sockets. */
Well, kind of:
* - This code cannot handle non-blocking sockets.
Also:
/* >output is a multiple of 8 byes, if len < rnum
* >we must be careful. The user must be aware that this
* >routine will write more bytes than he asked for.
* >The length of the buffer must be correct.
* FIXED - Should be ok now 18-9-90 - eay */
Or
/* This is really a bad error - very bad
* It will stuff-up both ends. */
Or
#ifdef _LIBC
extern unsigned long time();
extern int write();
#endif
I can't even...
Delete, delete, delete.
ok jsing
|
|
/*
* This header only exists to break a circular dependency between pem and err
* Ben 30 Jan 1999.
*/
25 years of uselessness is about a quarter century more than enough.
discussed with jsing
|
|
ok jsing
|
|
|
|
|
|
These files are now built on all platforms.
|
|
This is now built on all platforms.
|
|
|
|
Buy a vowel at the same time, since we're no longer limited to 8.3 file
names.
Discussed with tb@
|
|
This is now built on all platforms.
|
|
|
|
ok tb@
|
|
|
|
This is now built on all platforms.
|
|
Now that all platforms use a C des implementation, move it to the primary
Makefile.
|
|
Discussed with tb@
|
|
|