Navigacija
Lista poslednjih: 16, 32, 64, 128 poruka.

Neki MACROI ...nemam ti ja veze sa ovim prijatelju

[es] :: C programiranje :: Neki MACROI ...nemam ti ja veze sa ovim prijatelju

[ Pregleda: 1006 | Odgovora: 2 ]

Postavi temu Odgovori

Autor

Pretraga teme: Traži
Markiranje Štampanje RSS

Qlex
Ivan Kušaković
Beograd

Član broj: 21253
Poruke: 180
*.beg.sezampro.yu



Profil

icon Neki MACROI ...nemam ti ja veze sa ovim prijatelju23.02.2004. u 01:18

Cao svima...

Jedan moj drug iz Rusije treba pomoc u C++ pa mi se obratio, a ja bas i ne radim u C++ ...

Evo sta mi je poslao, ako mozete probajte da skrpite iz ovog nesto..ja blage veze nemam, ali razumem za ovo sto je rekao sa MsgBoxom i razumem to da mu ne odgovara sintaksa tog sto je pisao u VC++ , prevarant mali..


i have an _asm macros that is used in Borland C++ program. i need to change it's syntax to compile it with C++. it is just a one little .cpp file with a short asm macros above Main()

so. there is Main function. above it is an assembler macros, that is called from Main function. This macros purpose is to encrypt a compiled Visual C++ .exe file. I mean when you will compile this .cpp to .exe and will open it in any editor (HEX) you will not see string "*.exe" . it will be encrypted! and will be decrypted and displayed when you'll run it.

so it is a code for Borland C++. I'm trying to port it to Visual C++ but have some (syntax?) errors


this shit is to encrypt string in your file while it is compiling


for example, listen. you have a program that displays MsgBox "Copyright (c) 2004 Strorm". OK?

you compile it..

and you have exe-file

now, i can open this exe file, find string "copyright" and change it to "copyright (c) Roman"

using this macros will encrypt a string and it will be strored in file encrypted



Evo i koda :
Code:

#include <stdio.h>
#include <stdlib.h>
#define STOSD_STR(outvar, instr)   \
        {                          \
          asm                      \
          {                        \
            lea edi, outvar      ; \
            irpc c, <instr>      ; \
              mov al, '&c'       ; \
              stosb              ; \
            endm                 ; \
            xor eax, eax         ; \
            stosb                ; \
          }                        \
        }
void main()
{
  char mask[260];
  STOSD_STR(mask, "*.exe");
  printf("mask=%s\n", mask);
}



Hvala unapred



Sva velika buduća carstva biće carstva uma [..:Vinston Čercil , 1953:..]


23.02.2004. u 01:18 

NastyBoy
Bojan Nastic
UK

Član broj: 12041
Poruke: 895
*.in-addr.btopenworld.com



Profil

icon Re: Neki MACROI ...nemam ti ja veze sa ovim prijatelju23.02.2004. u 10:15
Neka zameni
asm {

sa

__asm {
23.02.2004. u 10:15 

Qlex
Ivan Kušaković
Beograd

Član broj: 21253
Poruke: 180
*.beg.sezampro.yu



Profil

icon Re: Neki MACROI ...nemam ti ja veze sa ovim prijatelju23.02.2004. u 13:52
ok
hvala ti

Reci cu mu da tako pokusa...



Sva velika buduća carstva biće carstva uma [..:Vinston Čercil , 1953:..]


23.02.2004. u 13:52 

[es] :: C programiranje :: Neki MACROI ...nemam ti ja veze sa ovim prijatelju

[ Pregleda: 1006 | Odgovora: 2 ]

Postavi temu Odgovori

Navigacija
Lista poslednjih: 16, 32, 64, 128 poruka.