From: beto@plan9.cs.su.oz.au beto@plan9.cs.su.oz.au
Subject: encrypt/decrypt not thread safe
Date: Tue, 15 Oct 1996 16:02:29 -0700 [thread overview]
Message-ID: <19961015230229.bMAD2Ckdf5gOqIWmKfMVrhyG_HFACRyhL2TN6wJAIvs@z> (raw)
Tracing a kernel bug we found that encrypt/decrypt
are not multi-thread safe. They save some values
in global memory. This is ok for user programs but
can cause authentication errors inside the kernel.
Those are the static variables used in des_encrypt:
/*
* The current block, divided into 2 halves.
*/
static char L[64], *R = L+32;
static char tempL[32];
static char f[32];
/*
* The combination of the key and the input, before selection.
*/
static char preS[48];
Could I move those variables inside des_encrypt???
I compiles but I'm not sure the code would be correct, some
reference could be set to L, temp, or f?
Any comments would be appreciated.
next reply other threads:[~1996-10-15 23:02 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
1996-10-15 23:02 beto [this message]
1996-10-16 6:07 forsyth
1996-10-16 6:09 forsyth
1996-10-16 7:03 Christopher.Vance
1996-10-16 7:49 forsyth
1996-10-17 9:07 Boyd
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=19961015230229.bMAD2Ckdf5gOqIWmKfMVrhyG_HFACRyhL2TN6wJAIvs@z \
--to=beto@plan9.cs.su.oz.au \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).