CodeEngn Logo

Challenges : Malware 05


Author : CodeEngn

Korean :
다음은 악성코드 소스의 일부분이다.
무엇을 하는 함수인가
(정답은 모두 소문자, 띄어쓰기 없음)

English :
This file is a source code of a malware.
What does this function do
(Answer must be all in lowercase, with no spaces)

int Malware_L03(char *StartOfData,char *Output,int SizeOfData)
{
	int encoded=0,i,l=0;
	char Table[]="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
	long buffer,buffer2;
	do
	{
		...
		for(i=3;i>=0;i--,l++)
		{
			buffer2=buffer;
			buffer2 &= 0x3f;
			*(Output + i)=Table[buffer2];
			buffer>>=6;
		}
		Output+=4;
		encoded+=4;
		SizeOfData-=3;
		if(l==76 && SizeOfData>3)
		{
			*Output=0xd;
			Output++;
			*Output=0xa;
			Output++;
			encoded+=2;
			l=0;
		}
		...
		
	}while(SizeOfData!=0);
	return encoded;
}


Linode is a privately owned virtual private server provider based in Galloway, New Jerse