Kuhasu's Blog

From sasCommunity

Jump to: navigation, search

Visit my personal webpage:Amwizard.googlepages.com


[edit] Hacker!Sasor!Whoever!

You can use sas process to collect information and email it through firewalls!*^_^*

Sounds like a talent hacker,isn't it?


Actually,it's another usage of sas for remote data process.


Remember: Use it good.

[edit] codes here:

1. creat a dataset.(You can omit it,'cause someone might do it for you:>)

/*Create an dataset*/

data sendmail;

input test;

cards;

1

2

3

5

;

run;

proc print data=sendmail;

run;

2. Save the output and the log(output can be created,but logs are not recommanded if you wanna hack something)

/*Save the output and the log*/

DM OUTPUT 'FILE "c:\send\test.OUT"';

DM LOG 'FILE "c:\send\test.LOG"';

3. Finally,send this output file as attachment to the email address you set

/*Send the output to mailbox*/

data _null_;

call system('c:\send\mailcmd "mail.xxxx.xxxx" "xxxx@gmail.com" "xxxx@gmail.com" "Subject: SAS results" "Contents: SAS results" "" "c:\send\readme.txt"');

run;

Don't wanna leave any information?Add delete codes.


Sample:

cmd.zip

Personal tools