91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 1.27MB
    文件類型: .rar
    金幣: 2
    下載: 0 次
    發(fā)布日期: 2023-11-15
  • 語言: 其他
  • 標(biāo)簽: AES??

資源簡介

包含 aes128/192/256 ecb cbc cfb ofb ctr純c代碼,vs2015工程,快速了解各種模式的加解密調(diào)用。參考資源:https://download.csdn.net/download/howiexue/9978483,改編簡單明了加解密例子,并且關(guān)鍵地方加了注釋。

資源截圖

代碼片段和文件信息

/*
---------------------------------------------------------------------------
Copyright?(c)?1998-2013?Brian?Gladman?Worcester?UK.?All?rights?reserved.

The?redistribution?and?use?of?this?software?(with?or?without?changes)
is?allowed?without?the?payment?of?fees?or?royalties?provided?that:

??source?code?distributions?include?the?above?copyright?notice?this
??list?of?conditions?and?the?following?disclaimer;

??binary?distributions?include?the?above?copyright?notice?this?list
??of?conditions?and?the?following?disclaimer?in?their?documentation.

This?software?is?provided?‘a(chǎn)s?is‘?with?no?explicit?or?implied?warranties
in?respect?of?its?operation?including?but?not?limited?to?correctness
and?fitness?for?purpose.
---------------------------------------------------------------------------
Issue?Date:?20/12/2007
*/

#ifndef?__GNUC__
#??include?
#endif
#include?
#include?“aes.h“
#include?“aesaux.h“
#include?“aestst.h“

#if?defined(__cplusplus)
extern?“C“
{
#endif

char?*st[8]?=?{?“vk“?“vt“?“nk“?“nt“?“me“?“md“?“me“?“md“?};

char?*file_name(char*?buf?size_t?len?const?unsigned?long?type?const?unsigned?long?blen?const?unsigned?long?klen)
{???char?*sp;

????if(len?????????return?0;
????sp?=?copy_str(buf?(type?????sp?=?copy_str(sp?st[type]);
????*sp++?=?(‘0‘?+?(char)blen?/?4);
????*sp++?=?(‘0‘?+?(char)klen?/?4);
????sp?=?copy_str(sp?“.txt“);
????*sp?=?‘\0‘;
????return?buf;
}

const?char?*pos(const?char?*s)
{
????while(*s++?!=?‘=‘)
????????;
????while(*s++?==?‘?‘)
????????;
????return?s?-?1;
}

//?Strings?to?locate?lines?in?test?vector?files

const?char?*fstr[NO_LTYPES]?=
????????{?BADL_STR?BLEN_STR?KLEN_STR?TEST_STR?IV_STR?KEY_STR?PT_STR?CT_STR?};

char????*hxx?=?“0123456789abcdef“;

//?Hexadecimal?conversion?from?hex?character?to?a?number?in?range?0?<=?no?<=?15

int?to_hex(int?ch)
{
????return?(ch?&?15)?+?(ch?>=?‘0‘?&&?ch?<=?‘9‘???0?:?9);
}

int?get_line(FILE?*inf?char?s[])
{
????if(feof(inf))
????????return?EXIT_FAILURE;

????return?fgets(s?100?inf)?!=?s???EXIT_FAILURE?:?EXIT_SUCCESS;
}

char?*copy_str(char?*d?const?char?*s)
{
????while(*s)
????????*d++?=?*s++;

????*d?=?‘\0‘;
????return?d;
}

char?*df_string(const?char?*f)
{???char?*p?=?f?*p1?*p2;
?
????p1?=?p2?=?0;
????while(*p)
????????if(*p++?==?‘\\‘)
????????{
????????????p1?=?p2;?p2??=?p;
????????}
????return?(p1???p1?:?p2???p2?:?f);
}

//?Read?from?a?string?of?hexadecimal?digits?into?an?array?of?8-bit?bytes
//?Each?pair?of?hexadecimal?digits?is?used?to?compile?one?8-bit?unsigned?char?and
//?the?first?(last)?digit?forms?the?most?(least)?significant?four?bits
//?of?each?unsigned?char.?The?hexadecimal?digits?are?read?from?left?(low)?to?right
//?(high)?and?are?placed?in?increasing?index?positions?in?the?unsigned?char?array

int?block_in(unsigned?char?l[]?const?char?*p)
{???int?i?=?0;

????p?=?pos(p);

????while(*p?&&?*(p?+?1)?&&?isxdigit(*p)?&&?isxdigit(*(p?+?1)))
????{
????????l[i++]?=?(to_hex(*p)?<

?屬性????????????大小?????日期????時(shí)間???名稱
-----------?---------??----------?-----??----

????..A..H.?????53248??2018-06-22?15:46??AES-Lib\.vs\AES-Lib\v14\.suo

?????文件???????8753??2017-07-21?06:45??AES-Lib\aes\aes.h

?????文件???????8032??2018-06-22?11:36??AES-Lib\aes\aes.vcxproj

?????文件???????2404??2018-06-22?11:36??AES-Lib\aes\aes.vcxproj.filters

?????文件????????165??2018-06-22?11:12??AES-Lib\aes\aes.vcxproj.user

?????文件??????10629??2018-06-19?16:08??AES-Lib\aes\aesaux.c

?????文件???????2749??2017-07-21?06:45??AES-Lib\aes\aesaux.h

?????文件??????10150??2017-07-21?06:45??AES-Lib\aes\aescrypt.c

?????文件??????16030??2017-07-21?06:45??AES-Lib\aes\aeskey.c

?????文件??????27513??2017-07-21?06:45??AES-Lib\aes\aesopt.h

?????文件??????15839??2017-07-21?06:45??AES-Lib\aes\aestab.c

?????文件???????5162??2017-07-21?06:45??AES-Lib\aes\aestab.h

?????文件???????6068??2018-06-22?11:37??AES-Lib\aes\aestst.c

?????文件??????11268??2017-07-21?06:45??AES-Lib\aes\aestst.h

?????文件????????197??2018-06-22?12:02??AES-Lib\aes\aes_main.c

?????文件??????30605??2017-07-21?06:45??AES-Lib\aes\aes_modes.c

?????文件??????18105??2017-07-21?06:45??AES-Lib\aes\aes_ni.c

?????文件???????2519??2017-07-21?06:45??AES-Lib\aes\aes_ni.h

?????文件??????17027??2017-07-21?06:45??AES-Lib\aes\aes_via_ace.h

?????文件???????5164??2017-07-21?06:45??AES-Lib\aes\brg_endian.h

?????文件???????7160??2017-07-21?06:45??AES-Lib\aes\brg_types.h

?????文件??????15966??2018-06-22?14:36??AES-Lib\aes\test_fun.c

?????文件????????162??2018-06-22?15:10??AES-Lib\aes\test_fun.h

?????文件???????2058??2018-06-22?14:42??AES-Lib\AES-Lib.sln

?????文件?????153600??2018-06-21?17:15??AES-Lib\aes_lib_bin\aes.dll

?????文件???????6428??2018-06-21?17:15??AES-Lib\aes_lib_bin\aes.lib

?????文件??????59392??2018-06-22?15:31??AES-Lib\aes_lib_bin\aes_lib_test.exe

?????文件?????366556??2018-06-22?15:31??AES-Lib\aes_lib_bin\aes_lib_test.ilk

?????文件?????634880??2018-06-22?15:31??AES-Lib\aes_lib_bin\aes_lib_test.pdb

?????文件?????153600??2018-06-21?17:15??AES-Lib\aes_lib_bin\dll_generic_c.dll

............此處省略234個(gè)文件信息

評論

共有 條評論