Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Encrypted Coldfusion code

Status
Not open for further replies.

gt196

Programmer
May 26, 2000
3
GB
I've recently (today) come across some encrypted ColdFusion code. Does anyone know how to replicate this effect or know any programs (I don't mind paying the price if they are good) that will replicate this.<br><br>Cheers,<br>Gordon<br>
 
In your /cfusion/bin directory, there is a command line utility called CFCRYPT.<br><br>You can use this to encrypt your code...&nbsp;&nbsp;The syntax is:<br><br><FONT FACE=monospace>CFCRYPT infile outfile [/r /q] [/h &quot;message&quot;] /v&quot;2&quot;</font><br><br>The options are:<br><br><FONT FACE=monospace><b>input file</b><br>Name of the file you want to encrypt. cfcrypt will not process an encrypted file.<br><br><b>output file</b><br>Path and filename of the output file. <i>Warning: If no output file name is specified, a warning message asks if you want to continue. If you continue the process, the encrypted file overwrites the source file.</i><br><br><b>/r</b><br>Recursive, when used with wildcards, recurses through subdirectories to encrypt files.<br><br><b>/q</b><br>Suppresses warning messages.<br><br><b>/h</b><br>Header, allows custom header to be written to the top of the encrypted file(s).<br><br><b>/v</b><br>Required parameter that allows encryption using a specified version number. Use &quot;1&quot; for pages you want to be able to run on ColdFusion 3.x. Use &quot;2&quot; for pages you want to run strictly on ColdFusion 4.0 and later.</font><br><br>Example:<br><FONT FACE=monospace>cfcrypt c:\myapp\myfile.cfm c:\myapp\encrypted\myfile.cfm /h &quot;this is an encrypted file&quot; /v &quot;2&quot;</font><br><br>This will encrypt the file &quot;myfile.cfm&quot; into a 4.0 or later encrypted file in the encrypted directory with a header &quot;This is an encrypted file&quot;<br><br>You'll want to specify a different path (probably a directory called &quot;encrypted&quot;??) for your encrypted than your plain text source code, or you'll lose your source....
 
hi, I just would like to follow-up a question for darkman.
I already had tried to encrypt coldfusion codes with the cfcrypt but when I browsed it from my local webserver, I can see completely my code though it is encrypted when I try to view it from the coldfusion editor. Why did it still displays the code or its code was in browser's cache.
thanks in advance
 
Here is a script to allow you to encrypt an entire web site in one go. (Also a heads up on &quot;recursion&quot;)


Sadly, this same technique works just as good in &quot;reverse&quot; using that &quot;alledged&quot; decrypt.exe file... so don't expect encryption to solve all your trouble.
 
Just remember that cfcrypt.exe is found in the \cfusion\bin directory of earlier versions of Coldfusion. Coldfusion 4.5 uses cfencode.exe instead.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top