亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? shsc.c

?? 簡單的RSA加密范例
?? C
字號:
/*	SHSC.C - Secure Hash Standard Code    Copyright (c) J.S.A.Kapp 1994 - 1996.	RSAEURO - RSA Library compatible with RSAREF(tm) 2.0.	All functions prototypes are the Same as for RSAREF(tm).	To aid compatiblity the source and the files follow the	same naming comventions that RSAREF(tm) uses.  This should aid	direct importing to your applications.	This library is legal everywhere outside the US.  And should	NOT be imported to the US and used there.	All Trademarks Acknowledged.	Revision history		0.90 first revision, initial implementation of the secure		hash standard FIPS PUB 180.        1.03 second revision, SHSFinal modified to output to a char        array specified by the user.*/#include "rsaeuro.h"#include "shs.h"/* The SHS Mysterious Constants */#define K1  0x5A827999L 	/* Rounds  0-19 */#define K2  0x6ED9EBA1L 	/* Rounds 20-39 */#define K3  0x8F1BBCDCL 	/* Rounds 40-59 */#define K4  0xCA62C1D6L     /* Rounds 60-79 *//* SHS initial values */#define Ainit 0x67452301L#define Binit 0xEFCDAB89L#define Cinit 0x98BADCFEL#define Dinit 0x10325476L#define Einit 0xC3D2E1F0L/* The SHS f()-functions */#define f1(x,y,z)   (( x & y ) | ( ~x & z ))              /* Rounds  0-19 */#define f2(x,y,z)   ( x ^ y ^ z )                         /* Rounds 20-39 */#define f3(x,y,z)   (( x & y ) | ( x & z ) | ( y & z ))   /* Rounds 40-59 */#define f4(x,y,z)   ( x ^ y ^ z )                         /* Rounds 60-79 *//* 32-bit rotate - kludged with shifts */#define S(n,X)	((X << n) | (X >> (32 - n)))/* The initial expanding function */#define expand(count)	W[count] = W[count - 3] ^ W[count - 8] ^ W[count - 14] ^ W[count - 16]/* The four SHS sub-rounds */#define subRound1(count)    \	{ \		temp = S(5, A) + f1(B, C, D) + E + W[count] + K1; \		E = D; \		D = C; \		C = S(30, B); \		B = A; \		A = temp; \	}#define subRound2(count)    \	{ \		temp = S(5, A) + f2(B, C, D) + E + W[count] + K2; \		E = D; \		D = C; \		C = S(30, B); \		B = A; \		A = temp; \	}#define subRound3(count)    \	{ \		temp = S(5, A) + f3(B, C, D) + E + W[count] + K3; \		E = D; \		D = C; \		C = S(30, B); \		B = A; \		A = temp; \	}#define subRound4(count)    \	{ \		temp = S(5, A) + f4(B, C, D) + E + W[count] + K4; \		E = D; \		D = C; \		C = S(30, B); \		B = A; \		A = temp; \	}/* The two buffers of 5 32-bit words */UINT4 h0, h1, h2, h3, h4;UINT4 A, B, C, D, E;static void byteReverse PROTO_LIST ((UINT4 *, int ));static void SHSTransform PROTO_LIST ((SHS_CTX *));static void Encode PROTO_LIST((unsigned char *, UINT4 *, unsigned int));/* Initialize the SHS values */void SHSInit(context)SHS_CTX *context;               /* context */{	/* Set the h-vars to their initial values */	context->digest[0] = Ainit;	context->digest[1] = Binit;	context->digest[2] = Cinit;	context->digest[3] = Dinit;	context->digest[4] = Einit;	/* Initialise bit count */	context->countLo = context->countHi = 0L;}/* Update SHS for a block of data.   This code assumes that the buffer size is a multiple of   SHS_BLOCKSIZE bytes long.*/void SHSUpdate(context, buffer, count)SHS_CTX *context;               /* context */BYTE *buffer;										/* input block */int count;                      /* length of input block */{	/* Update bitcount */	if((context->countLo + ((UINT4) count << 3)) < context->countLo)		 context->countHi++;	/* Carry from low to high bitCount */	context->countLo += ((UINT4) count << 3);	context->countHi += ((UINT4) count >> 29);	/* Process data in SHS_BLOCKSIZE chunks */	while(count >= SHS_BLOCKSIZE) {		R_memcpy((POINTER)context->data, buffer, SHS_BLOCKSIZE);		byteReverse(context->data, SHS_BLOCKSIZE);		SHSTransform(context);		buffer += SHS_BLOCKSIZE;		count -= SHS_BLOCKSIZE;	}	/* Handle any remaining bytes of data. */	R_memcpy((POINTER)context->data, buffer, count);}/* Finalize SHS hash, outputs to a unsigned char array.   array must be > 20 bytes in length.*/void SHSFinal(digest, context)BYTE *digest;SHS_CTX *context;               /* context */{	int count;	UINT4 lowBitcount = context->countLo, highBitcount = context->countHi;	/* Compute number of bytes mod 64 */	count = (int) ((context->countLo >> 3) & 0x3F);	/* Set the first char of padding to 0x80. */	((BYTE *) context->data)[count++] = 0x80;	/* Pad out to 56 mod 64 */	if(count > 56) {		/* Two lots of padding:  Pad the first block to 64 bytes */		R_memset((BYTE *) context->data + count, 0, 64 - count);		byteReverse(context->data, SHS_BLOCKSIZE);		SHSTransform(context);		/* Now fill the next block with 56 bytes */		R_memset((POINTER)context->data, 0, 56);	} else		/* Pad block to 56 bytes */		R_memset((BYTE *) context->data + count, 0, 56 - count);	byteReverse(context->data, SHS_BLOCKSIZE);	/* Append length in bits and transform */	context->data[14] = highBitcount;	context->data[15] = lowBitcount;	SHSTransform(context);	byteReverse(context->data, SHS_DIGESTSIZE);    Encode(digest, context->digest, 20);    R_memset((POINTER)context, 0, sizeof(SHS_CTX));}static void byteReverse(buffer, byteCount)UINT4 *buffer;int byteCount;{	UINT4 value;	int count;	/* Find out what the byte order is on this machine.		 Big endian is for machines that place the most significant byte		 first (eg. Sun SPARC). Little endian is for machines that place		 the least significant byte first (eg. VAX). */	if((*(unsigned short *) ("#P") >> 8) == '#')		return;	byteCount /= sizeof(UINT4);	for(count = 0; count < byteCount; count++) {		value = (buffer[count] << 16) | (buffer[count] >> 16);		buffer[count] = ((value & 0xFF00FF00L) >> 8) | ((value & 0x00FF00FFL) << 8);	}}/* Perform the SHS transformation. */static void SHSTransform(context)SHS_CTX *context;{	UINT4 W[80], temp;	int i;	/* Step 1.	Copy the data buffer into the local work buffer */	for(i = 0; i < 16; i++)		W[i] = context->data[i];	/* Step 2.	Expand the 16 words into 64 temporary data words */	expand(16); expand(17); expand(18); expand(19); expand(20);	expand(21); expand(22); expand(23); expand(24); expand(25);	expand(26); expand(27); expand(28); expand(29); expand(30);	expand(31); expand(32); expand(33); expand(34); expand(35);	expand(36); expand(37); expand(38); expand(39); expand(40);	expand(41); expand(42); expand(43); expand(44); expand(45);	expand(46); expand(47); expand(48); expand(49); expand(50);	expand(51); expand(52); expand(53); expand(54); expand(55);	expand(56); expand(57); expand(58); expand(59); expand(60);	expand(61); expand(62); expand(63); expand(64); expand(65);	expand(66); expand(67); expand(68); expand(69); expand(70);	expand(71); expand(72); expand(73); expand(74); expand(75);	expand(76); expand(77); expand(78); expand(79);	/* Step 3.	Set up first buffer */	A = context->digest[0];	B = context->digest[1];	C = context->digest[2];	D = context->digest[3];	E = context->digest[4];	/* Step 4.	Serious mangling, divided into four sub-rounds */	subRound1(0); subRound1(1); subRound1(2); subRound1(3);	subRound1(4); subRound1(5); subRound1(6); subRound1(7);	subRound1(8); subRound1(9); subRound1(10); subRound1(11);	subRound1(12); subRound1(13); subRound1(14); subRound1(15);	subRound1(16); subRound1(17); subRound1(18); subRound1(19);	subRound2(20); subRound2(21); subRound2(22); subRound2(23);	subRound2(24); subRound2(25); subRound2(26); subRound2(27);	subRound2(28); subRound2(29); subRound2(30); subRound2(31);	subRound2(32); subRound2(33); subRound2(34); subRound2(35);	subRound2(36); subRound2(37); subRound2(38); subRound2(39);	subRound3(40); subRound3(41); subRound3(42); subRound3(43);	subRound3(44); subRound3(45); subRound3(46); subRound3(47);	subRound3(48); subRound3(49); subRound3(50); subRound3(51);	subRound3(52); subRound3(53); subRound3(54); subRound3(55);	subRound3(56); subRound3(57); subRound3(58); subRound3(59);	subRound4(60); subRound4(61); subRound4(62); subRound4(63);	subRound4(64); subRound4(65); subRound4(66); subRound4(67);	subRound4(68); subRound4(69); subRound4(70); subRound4(71);	subRound4(72); subRound4(73); subRound4(74); subRound4(75);	subRound4(76); subRound4(77); subRound4(78); subRound4(79);	/* Step 5.	Build message digest */	context->digest[0] += A;	context->digest[1] += B;	context->digest[2] += C;	context->digest[3] += D;	context->digest[4] += E;    /* Clear sensitive information */	R_memset((POINTER) W, 0, sizeof(W));}/* Encode SHS output in char array */static void Encode(output, input, len)unsigned char *output;UINT4 *input;unsigned int len;{	unsigned int i, j;	for(i = 0, j = 0; j < len; i++, j += 4) {        output[j+3] = (unsigned char)(input[i] & 0xff);        output[j+2] = (unsigned char)((input[i] >> 8) & 0xff);        output[j+1] = (unsigned char)((input[i] >> 16) & 0xff);        output[j] = (unsigned char)((input[i] >> 24) & 0xff);	}}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
夜夜爽夜夜爽精品视频| av网站免费线看精品| 激情av综合网| 一本一道综合狠狠老| 日韩你懂的在线观看| 中文字幕一区二区三区色视频| 日韩1区2区日韩1区2区| 99riav久久精品riav| 欧美tickling挠脚心丨vk| 樱桃视频在线观看一区| 成人美女视频在线看| 2023国产精品视频| 日韩成人免费电影| 色美美综合视频| 国产欧美va欧美不卡在线 | 欧美巨大另类极品videosbest| 国产欧美精品一区aⅴ影院| 久久黄色级2电影| 91麻豆精品91久久久久久清纯 | 欧美日韩三级一区| 亚洲欧洲性图库| 成人综合婷婷国产精品久久蜜臀 | 日韩精品一区在线| 亚洲欧美国产毛片在线| 国产精品一区二区果冻传媒| 国产91丝袜在线观看| 91精品国产色综合久久不卡蜜臀| 国产精品久久久久国产精品日日| 毛片av中文字幕一区二区| 91免费在线播放| 国产精品免费视频观看| 麻豆成人综合网| 欧美精品aⅴ在线视频| 国产精品国产三级国产a | 日韩免费在线观看| 午夜久久久久久久久| 在线一区二区三区做爰视频网站| 中文字幕乱码久久午夜不卡| 国产99久久久精品| 国产精品福利一区二区三区| 波多野结衣一区二区三区| 国产亚洲精久久久久久| 激情偷乱视频一区二区三区| 精品日产卡一卡二卡麻豆| 天天影视色香欲综合网老头| 欧美专区亚洲专区| 亚洲啪啪综合av一区二区三区| 成人性色生活片免费看爆迷你毛片| 精品久久免费看| 五月天激情综合网| 成人国产在线观看| 欧美激情综合五月色丁香小说| 国产一区久久久| 久久综合99re88久久爱| 国产成人av电影| 国产精品人人做人人爽人人添| 成人av在线一区二区| 17c精品麻豆一区二区免费| 91麻豆精品一区二区三区| 一区二区三区在线观看动漫| 欧美色图在线观看| 午夜久久久影院| 精品国精品自拍自在线| 懂色av中文一区二区三区| 中文在线一区二区| 91国在线观看| 日韩高清在线一区| 欧美xxx久久| 不卡av免费在线观看| 国产精品免费人成网站| 99久久精品99国产精品| 亚洲动漫第一页| 精品国产乱码久久久久久闺蜜| 国产乱妇无码大片在线观看| 国产精品你懂的| 欧美久久免费观看| 国产精品77777| 亚洲免费伊人电影| 欧美一区二区三区在线| 国产成人亚洲精品青草天美| 亚洲欧美日韩在线| 欧美草草影院在线视频| eeuss影院一区二区三区| 亚洲成av人片一区二区| 久久久久国产精品人| 日本高清不卡在线观看| 卡一卡二国产精品 | 欧美日韩一区久久| 紧缚捆绑精品一区二区| 亚洲免费成人av| 欧美成人精品二区三区99精品| 91在线免费视频观看| 喷白浆一区二区| 亚洲欧美成人一区二区三区| 日韩欧美国产一区二区在线播放 | 国产成人精品www牛牛影视| 亚洲自拍偷拍网站| 久久久久久久久久久久久久久99| 在线观看亚洲精品视频| 免费观看一级特黄欧美大片| 久久久久久久综合日本| 欧美日韩一区久久| 不卡的av在线| 国产麻豆精品一区二区| 亚洲va欧美va国产va天堂影院| 中文在线资源观看网站视频免费不卡 | 91麻豆国产精品久久| 看电影不卡的网站| 偷拍与自拍一区| 一区二区激情小说| 国产精品久久毛片av大全日韩| 久久日韩粉嫩一区二区三区| 欧美日韩国产另类一区| 日本国产一区二区| www.欧美日韩国产在线| 国产成人日日夜夜| 国产一区二三区好的| 久久国产精品露脸对白| 美女爽到高潮91| 美国av一区二区| 蜜臀av性久久久久蜜臀aⅴ四虎| 成人免费一区二区三区在线观看| 久久婷婷久久一区二区三区| 久久综合中文字幕| 精品国产123| 精品国产免费一区二区三区香蕉| 日韩精品一区国产麻豆| 欧美一区二区免费观在线| 欧美日韩专区在线| 欧美日韩视频一区二区| 9191成人精品久久| 欧美一级夜夜爽| 日韩精品一区二| 精品国产一区二区亚洲人成毛片| 日韩欧美国产电影| 欧美不卡视频一区| 久久精品亚洲精品国产欧美kt∨| 2020国产精品自拍| 日韩欧美一级在线播放| 91麻豆自制传媒国产之光| caoporn国产精品| www.色综合.com| 欧美性一二三区| 3d动漫精品啪啪一区二区竹菊 | 日韩av二区在线播放| 美国十次了思思久久精品导航| 久88久久88久久久| 国产一区不卡在线| 波多野结衣中文字幕一区二区三区| 久久99国产精品麻豆| 日韩1区2区日韩1区2区| 成人天堂资源www在线| 91丨porny丨蝌蚪视频| 欧美日免费三级在线| 日韩一区二区三区观看| 久久综合资源网| 国产精品国产自产拍高清av| 亚洲一卡二卡三卡四卡| 日韩国产在线一| 国产精品1区2区3区在线观看| 99精品国产91久久久久久| 欧美日韩一区久久| 久久久综合视频| 亚洲婷婷综合色高清在线| 婷婷综合久久一区二区三区| 国内精品自线一区二区三区视频| 盗摄精品av一区二区三区| 欧美色欧美亚洲另类二区| 2021久久国产精品不只是精品| 日韩码欧中文字| 美日韩一区二区| 91视视频在线直接观看在线看网页在线看| 欧美日韩mp4| 中文字幕精品三区| 日韩电影在线免费| 国产精品一区二区91| 538prom精品视频线放| 国产精品三级av在线播放| 天天综合日日夜夜精品| 波多野结衣亚洲一区| 日韩精品一区二区三区四区 | 日韩欧美一区二区在线视频| 中文字幕不卡一区| 麻豆久久久久久久| 成人美女在线观看| 精品视频在线看| 国产欧美一区二区精品性色| 日韩综合在线视频| 色偷偷88欧美精品久久久| 精品国免费一区二区三区| 亚洲成人av中文| 色综合久久六月婷婷中文字幕| 欧美精品一区二区三区在线播放 | 免费看精品久久片| 一道本成人在线| 国产三级精品视频| 蜜桃在线一区二区三区| 欧美色视频在线| 亚洲乱码中文字幕综合| 成人在线综合网|