MASM encryption (UNICODE Example)

; encrypted with www.stringencrypt.com (v1.0.0) [MASM Assembler (32 bit)]
 
.data
 
	; szString = "MASM Assembler Encryption"
	szString dw 0B713h, 0B718h, 0B70Fh, 0B6EEh, 0B774h, 0B714h, 0B72Bh, 0B724h
                 dw 0B733h, 0B704h, 0B730h, 0B707h, 0B70Fh, 0B723h, 0B74Eh, 0B6EAh
                 dw 0B702h, 0B70Eh, 0B738h, 0B732h, 0B734h, 0B731h, 0B71Dh, 0B718h
                 dw 0B71Ah, 0B721h
 
.code
	mov	ebx, offset szString
	mov	ecx, 26
	and	eax, 0
 
@@:
	mov	dx, word ptr [ebx + eax]
	xor	edx, 0BA13h
	inc	edx
	not	edx
	sub	edx, eax
	xor	edx, 0F2B3h
	mov	word ptr [ebx + eax], dx
	inc	eax
	dec	ecx
	jne	@b
 
	push	0
	push	ebx
	push	ebx
	push	0
	call	MessageBoxW

MASM encryption (ANSI Example)

; encrypted with www.stringencrypt.com (v1.0.0) [MASM Assembler (32 bit)]
 
.data
 
	; szString = "Encryption in MASM"
	szString db 095h, 0AFh, 0B9h, 0A9h, 09Dh, 0A5h, 0A0h, 0AAh
                 db 0A7h, 0A7h, 070h, 0A6h, 0A4h, 06Dh, 07Fh, 08Ah
                 db 07Bh, 07Ch, 048h
 
.code
	mov	ebx, offset szString
	mov	eax, 19
	xor	ecx, ecx
 
@@:
	mov	dl, byte ptr [ebx + ecx]
	not	edx
	sub	edx, ecx
	sub	edx, 0C2h
	sub	edx, ecx
	add	edx, ecx
	not	edx
	inc	edx
	xor	edx, 01Dh
	mov	byte ptr [ebx + ecx], dl
	inc	ecx
	dec	eax
	jne	@b
 
	push	0
	push	ebx
	push	ebx
	push	0
	call	MessageBoxA