Notices
Computer & Technology Related Post here for help and discussion of computing and related technology. Internet, TVs, phones, consoles, computers, tablets and any other gadgets.

Encrypt a batch file - Urgent

Thread Tools
 
Search this Thread
 
Old 18 April 2007, 03:04 PM
  #1  
GazTheHat
Scooby Regular
Thread Starter
 
GazTheHat's Avatar
 
Join Date: Aug 2005
Location: 392/361 MY04 STi
Posts: 7,638
Likes: 0
Received 0 Likes on 0 Posts
Default Encrypt a batch file - Urgent

I'm no windows/dos guru.

I have a .bat file scheduled to run daily. This runs ftp, the FTP details are in a .dat file

The bat & dat file details need to be encrypted, or put in an .exe, so the user cannot see what it does and what the ftp login details are.

Anyone know how to do this?
Old 18 April 2007, 04:14 PM
  #2  
GazTheHat
Scooby Regular
Thread Starter
 
GazTheHat's Avatar
 
Join Date: Aug 2005
Location: 392/361 MY04 STi
Posts: 7,638
Likes: 0
Received 0 Likes on 0 Posts
Default

Been told i can put it all in VBScript.

Anyone have an example i could use?
Old 18 April 2007, 06:06 PM
  #3  
GazTheHat
Scooby Regular
Thread Starter
 
GazTheHat's Avatar
 
Join Date: Aug 2005
Location: 392/361 MY04 STi
Posts: 7,638
Likes: 0
Received 0 Likes on 0 Posts
Default

Sorted now.
Old 18 April 2007, 06:16 PM
  #4  
HankScorpio
Scooby Regular
 
HankScorpio's Avatar
 
Join Date: Feb 2004
Posts: 5,848
Likes: 0
Received 0 Likes on 0 Posts
Default

Just out of interest, what did you do?

In the past, we've put the account details in an ntfs protected file that only the account running the job can see. Not ideal but gets round the main problem.
Old 19 April 2007, 03:49 PM
  #5  
GazTheHat
Scooby Regular
Thread Starter
 
GazTheHat's Avatar
 
Join Date: Aug 2005
Location: 392/361 MY04 STi
Posts: 7,638
Likes: 0
Received 0 Likes on 0 Posts
Default

For the FTP command, the -s flag was being used. In that file were the ftp commands, including username password.

So now, create the ftp file on the fly, just:

@echo off
echo username > ftpfile
echo password >> ftpfile
ftp -s:ftpfile theserver
del ftpfile

Then ran a batch file compiler on that .bat, to create an unreadable .exe

All details encrypted.
Old 20 April 2007, 10:26 AM
  #6  
judgejules
Scooby Regular
 
judgejules's Avatar
 
Join Date: Nov 2000
Posts: 1,227
Likes: 0
Received 0 Likes on 0 Posts
Default

Um, hate to burst your bubble mate, but the whole batch file will be in the exe somewhere, usually at the end, which will take two seconds to see if you drop it into notepad. Unless you're using some uber cmd2exe compiler that encrypts the compiled bat file and decrypts it on the fly?

EXE's dont equal encrypted, there is plenty of human readable stuff stored in exe's.

Dont know if you realise this, just fyi.

J
Old 20 April 2007, 04:17 PM
  #7  
GazTheHat
Scooby Regular
Thread Starter
 
GazTheHat's Avatar
 
Join Date: Aug 2005
Location: 392/361 MY04 STi
Posts: 7,638
Likes: 0
Received 0 Likes on 0 Posts
Default

Originally Posted by judgejules
Um, hate to burst your bubble mate, but the whole batch file will be in the exe somewhere, usually at the end, which will take two seconds to see if you drop it into notepad. Unless you're using some uber cmd2exe compiler that encrypts the compiled bat file and decrypts it on the fly?

EXE's dont equal encrypted, there is plenty of human readable stuff stored in exe's.

Dont know if you realise this, just fyi.

J
Was compiled with Quick Batch File Compiler. Editing the .exe just produces heiroglyphics (or however you spell it)

Was also able to select "Ghost Mode" so not even a command window comes up. As stealthy as Sam Fisher.
Old 20 April 2007, 04:40 PM
  #8  
judgejules
Scooby Regular
 
judgejules's Avatar
 
Join Date: Nov 2000
Posts: 1,227
Likes: 0
Received 0 Likes on 0 Posts
Default

Originally Posted by GazTheHat
Was compiled with Quick Batch File Compiler. Editing the .exe just produces heiroglyphics (or however you spell it)

Was also able to select "Ghost Mode" so not even a command window comes up. As stealthy as Sam Fisher.
Oh thats a nice little app. Encrypted with password protection to stop decomilation through the app, good find.

J
Related Topics
Thread
Thread Starter
Forum
Replies
Last Post
yabbadoo4
ScoobyNet General
11
30 September 2015 10:33 PM
Nick_Cat
Computer & Technology Related
2
26 September 2015 08:00 AM
Littleted
Computer & Technology Related
0
25 September 2015 08:44 AM
ALi-B
Computer & Technology Related
0
14 September 2015 07:49 AM
riiidaa
ScoobyNet General
1
12 September 2015 11:52 AM



Quick Reply: Encrypt a batch file - Urgent



All times are GMT +1. The time now is 02:22 AM.