Commit Graph

6 Commits

Author SHA1 Message Date
Denis Vlasenko
d324e1b808 libbb/crypt: code shrink
function                                             old     new   delta
to64_msb_first                                         -      63     +63
des_crypt                                           1509    1338    -171
------------------------------------------------------------------------------
(add/remove: 1/0 grow/shrink: 0/1 up/down: 63/-171)          Total: -108 bytes
2008-12-04 15:29:35 +00:00
Denis Vlasenko
e9b9a19ad3 libbb: disable a second md5 implementation which managed to creep in :)
function                                             old     new   delta
sha512_end                                           239     237      -2
sha256_end                                           162     160      -2
sha1_end                                             191     189      -2
md5_end                                              168     166      -2
__md5__magic                                           4       -      -4
md5_crypt                                            627     621      -6
static.S                                              16       -     -16
__md5_Init                                            42       -     -42
static.P                                              64       -     -64
__md5_Final                                          131       -    -131
__md5_Update                                         153       -    -153
static.C                                             268      12    -256
__md5_Transform                                      293       -    -293
------------------------------------------------------------------------------
(add/remove: 0/7 grow/shrink: 0/6 up/down: 0/-973)           Total: -973 bytes
2008-11-11 01:38:04 +00:00
Denis Vlasenko
2211d5268c libbb: add optionl support for SHA256/512 encrypted passwords
function                                             old     new   delta
sha_crypt                                              -    2423   +2423
cryptpw_main                                         128     183     +55
to64                                                   -      29     +29
pw_encrypt                                           974    1000     +26
str_rounds                                             -      11     +11
login_main                                          1532    1541      +9
packed_usage                                       25215   25200     -15
__md5_to64                                            29       -     -29
------------------------------------------------------------------------------
(add/remove: 3/1 grow/shrink: 3/1 up/down: 2553/-44)         Total: 2509 bytes
2008-11-10 18:52:35 +00:00
Denis Vlasenko
e235285c3a crypt: code shrink
function                                             old     new   delta
des_crypt                                              -    1682   +1682
md5_crypt                                              -     627    +627
pw_encrypt                                          3608    1036   -2572
------------------------------------------------------------------------------
(add/remove: 2/0 grow/shrink: 0/1 up/down: 2309/-2572)       Total: -263 bytes
2008-06-14 22:11:29 +00:00
Denis Vlasenko
76f812803b trivial crypt shrinkage
function                                             old     new   delta
__md5_to64                                            27      29      +2
pw_encrypt                                          3631    3608     -23
2008-06-13 15:13:41 +00:00
Denis Vlasenko
4ea83bf562 uclibc insists on having 70k static buffer for crypt.
For bbox it's not acceptable. Roll our own des and md5 crypt
implementation. Against older uclibc:

   text    data     bss     dec     hex filename
 759945     604    6684  767233   bb501 busybox_old
 759766     604    6684  767054   bb44e busybox_unstripped

so, we still save on code size.
2008-06-12 16:55:59 +00:00