Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Encrypt a javascript/url variable with a coldfusion function

Posted on 2006-11-01
5
Medium Priority
?
434 Views
Last Modified: 2013-12-20
I have a page that passes information to another file which inserts that info into a DB via url variable.  the url variable is passed to the page that does the insert/update asynchronously using javascript.   What i would liek to do is enrypt that url variable before it gets sent via the ajax call.  I am hoping that there is a) a javascript function that can act liek the cf encrypt() function or b use wddx somehow to pass the information between js and cf before being sent via the url.
0
Comment
Question by:jduawa
  • 3
5 Comments
 
LVL 36

Expert Comment

by:SidFishes
ID: 17851854
are you trying to obscure the url value or simply trying to encrypt the ajax call?

If you are passing sensitive data via ajax just use https instead of http in the script call
0
 
LVL 20

Expert Comment

by:trailblazzyr55
ID: 17851861
here's a javascript function you can do that does a type of encryption... I don't believe there is a built in function like CF has..

http://javascript.internet.com/passwords/xor-encryption4.html
0
 
LVL 20

Accepted Solution

by:
trailblazzyr55 earned 2000 total points
ID: 17851878
here's another javascript string encryption method, bit better than the previous...

http://pajhome.org.uk/crypt/md5/
0
 
LVL 1

Author Comment

by:jduawa
ID: 17851910
i think what i will have to do is create or use an existing javascript function to encrypt the url variable before it is passed then on the page that processes it ieither use a ajvascript function to decrypt it or write a small java program to do the decrytion and call that with CF
thanks for th einiput
0
 
LVL 20

Expert Comment

by:trailblazzyr55
ID: 17851962
Glad I could help! And good luck, let us know if you have any more questions...

Thanks,
~trail
0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Turn A Profile Picture Into A Cartoon Using Photoshop And Illustrator This tutorial will teach you how to make a cartoon style image out of a regular picture. I have tried to keep the tutorial as simple as possible. I used Adobe CS4 for this tuto…
Article by: kevp75
Hey folks, 'bout time for me to come around with a little tip. Thanks to IIS 7.5 Extensions and Microsoft (well... really Windows 8, and IIS 8 I guess...), we can now prime our Application Pools, when IIS starts. Now, though it would be nice t…
The purpose of this video is to demonstrate how to create a Printer Friendly PDF on a WordPress Page. This will be demonstrated using a Windows 8 PC. Tools Used are Photoshop, Awesome Screenshot” Google Chrome Extension, and SmallPDF.com Log…
The purpose of this video is to demonstrate how to set up the permalinks on a WordPress Website. This will be demonstrated using a Windows 8 PC. Go to your WordPress login page. This will look like the following: mywebsite.com/wp-login.php : Go t…
Suggested Courses

927 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question