473,407 Members | 2,598 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,407 software developers and data experts.

One-way permutation in ASP?

Hello all,

I'm looking for a free method to apply a one-way encryption to a 64-bit
value in an ASP script. Does anyone have any links to existing code or at
least a process that I can follow to develop it myself?

Thanks!

--
Mike
Jul 19 '05 #1
7 2331
"Mike" wrote:

I'm looking for a free method to apply a one-way encryption
to a 64-bit value in an ASP script. Does anyone have any
links to existing code or at least a process that I can
follow to develop it myself?


[val%2] is a one-way hash, but I suppose you want to map onto a bit larger
space.

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms. Please do not contact
me directly or ask me to contact you directly for assistance. If your
question is worth asking, it's worth posting.
Jul 19 '05 #2
"Dave Anderson" <GT**********@spammotel.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
"Mike" wrote:

I'm looking for a free method to apply a one-way encryption
to a 64-bit value in an ASP script. Does anyone have any
links to existing code or at least a process that I can
follow to develop it myself?


[val%2] is a one-way hash, but I suppose you want to map onto a bit larger
space.


I should have been a bit more specific... I want to take my 64 bit value and
apply a process to it that will yield a unique value that cannot be easily
reversed back to the original value.

I will have a database with 13000 unique 64-bit identifiers, but those
identifiers have been deemed mildly sensitive by a higher power. Now, I
would rather have a database with 13000 non-sensitive unique identifiers,
each of which can be obtained by applying a process to the original
sensitive identifier. Thus if my server is compromised (or the server of a
third party that will host the same data) I won't have to worry about the
revelation of these identifiers (not SS numbers BTW).

I found several links in the ASP FAQ, but nothing free that meets this
requirement. I might just have to pay or move on to Linux, but I was
checking first. :)

--
Mike
Jul 19 '05 #3
"Mike" wrote:

I should have been a bit more specific... I want to take my 64
bit value and apply a process to it that will yield a unique
value that cannot be easily reversed back to the original value.
"One-way" permutations cannot be inverted at all, much less easily. And
uniqueness implies invertibility. You have to choose between uniqueness and
non-invertibility.
I will have a database with 13000 unique 64-bit identifiers,
but those identifiers have been deemed mildly sensitive by a
higher power. Now, I would rather have a database with 13000
non-sensitive unique identifiers, each of which can be
obtained by applying a process to the original sensitive
identifier. Thus if my server is compromised (or the server
of a third party that will host the same data) I won't have
to worry about the revelation of these identifiers (not SS
numbers BTW).

I found several links in the ASP FAQ, but nothing free that
meets this requirement. I might just have to pay or move on
to Linux, but I was checking first.


This one is only $30:
http://www.sewelld.com/SecureHashAlgorithm.asp
--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms. Please do not contact
me directly or ask me to contact you directly for assistance. If your
question is worth asking, it's worth posting.
Jul 19 '05 #4
MD5 and SHA1 are one-way hash functions (permutation is not quite the
right word). SHA1 is better than MD5. By applying the function to your
data, you get a resulting value that is highly unique, a signature. It
is also computationally infeasible to recover the original data from the
hash value.

Some free implementations in ASP are here:

http://www.frez.co.uk/freecode.htm

Free Javascript implementations are here:

http://pajhome.org.uk/crypt/md5/index.html

Shailesh
Mike wrote:
Hello all,

I'm looking for a free method to apply a one-way encryption to a 64-bit
value in an ASP script. Does anyone have any links to existing code or at
least a process that I can follow to develop it myself?

Thanks!

--
Mike


Jul 19 '05 #5
I get the impression from other messages in this thread that the resultant
value must be "guaranteed" unique. Perhaps the original poster can clarify.
Will the resulting value be used to look up specific records in a table?
Must the value be unique?

--
Mark Schupp
--
Head of Development
Integrity eLearning
Online Learning Solutions Provider
ms*****@ielearning.com
http://www.ielearning.com
714.637.9480 x17
"Shailesh Humbad" <hu******@hotmail.com> wrote in message
news:hl**********************@twister.columbus.rr. com...
MD5 and SHA1 are one-way hash functions (permutation is not quite the
right word). SHA1 is better than MD5. By applying the function to your
data, you get a resulting value that is highly unique, a signature. It
is also computationally infeasible to recover the original data from the
hash value.

Some free implementations in ASP are here:

http://www.frez.co.uk/freecode.htm

Free Javascript implementations are here:

http://pajhome.org.uk/crypt/md5/index.html

Shailesh
Mike wrote:
Hello all,

I'm looking for a free method to apply a one-way encryption to a 64-bit
value in an ASP script. Does anyone have any links to existing code or at least a process that I can follow to develop it myself?

Thanks!

--
Mike

Jul 19 '05 #6
"Mike" <so***@sorry.com> wrote in message
news:be*********@geraldo.cc.utexas.edu...
I like that solution and it met all of my requirements! However, I just
found another requirement from the third party... 44 characters max for the identifier. The unique identifier produced by the code is 64 characters... Arrrrrghhh... :)

I'll work on the third party. :)


MD5 meets all of the criteria (I was basing the above on SHA), Thanks again!

--
Mike
Jul 19 '05 #7
SHA-256 produces a 256 bit hash value. Hexadecimal represents 4 bits
per character, so the value needs 256/4 = 64 characters of space.
However, a character can actually hold 8 bits (or 16 bits if Unicode),
so if you store the hash value in binary form, it can fit in 256/8 = 32
'characters' or bytes of space. If your third party does not require
the identifier to be readable/typable by an end-user, then you can just
store the hash value in binary using 32 bytes/characters of space. BTW,
if you use SHA-1, you get a 160 bit hash value, which only takes up 40
characters of space even in hexadecimal form.

Shailesh

Mike wrote:
"Shailesh Humbad" <hu******@hotmail.com> wrote in message
news:hl**********************@twister.columbus.rr. com...
MD5 and SHA1 are one-way hash functions (permutation is not quite the
right word). SHA1 is better than MD5. By applying the function to your
data, you get a resulting value that is highly unique, a signature. It
is also computationally infeasible to recover the original data from the
hash value.

Some free implementations in ASP are here:

http://www.frez.co.uk/freecode.htm

I like that solution and it met all of my requirements! However, I just
found another requirement from the third party... 44 characters max for the
identifier. The unique identifier produced by the code is 64 characters...
Arrrrrghhh... :)

I'll work on the third party. :)

Thanks!

--
Mike


Jul 19 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

18
by: M. Clift | last post by:
Hi, Just a quick one. I'm trying to call with this, but I keep getting 'unhashable'. I've tried various ' " and nextName = {:,\ 'Rita':],\ 'Sue':],\ 'Mary':}
3
by: Hamed | last post by:
Hello Every where in .NET books is mentioned that VS.NET is a seamless cross platform environment. We have two groups of programmers that some are VB programmer but others prefer to use C#. Is it...
20
by: Felix E. Klee | last post by:
Hi, when I compile the program below with gcc -O0 -o ctest ctest.c (Platform: Intel Celeron (Coppermine), LINUX 2.4.20) I get the following output: one != one_alt one_alt != one 1. !=...
14
by: serge | last post by:
I have a scenario where two tables are in a One-to-Many relationship and I need to move the data from the Many table to the One table so that it becomes a One-to-One relationship. I need to...
15
by: kimi | last post by:
I have just started working on a project that is partially complete. It is an application that is using access to store test results. The test results are being stored in two Access 2000 databases....
2
by: ronenkf | last post by:
I am currently working on access 2003. Created database with 4 tables. For each on e there is a primary key, which is a text data type. Now I'm trying to configure relationship between tables. The...
3
by: Douwe | last post by:
I try to build my own version of printf which just passes all arguments to the original printf. As long as I keep it with the single argument version everything is fine. But their is also a version...
3
by: nasirmajor | last post by:
dear all, a simple quetion for database experts. can three datatables be updated at the same time (from one page)with one table having one primary key and other two tables are having that primary...
2
by: Sky | last post by:
Hello: I'm trying to make sense of snk files, when to use, under what conditions to regenerate new ones,...can someone take a look if these statemes make sense? And then the final questions at the...
0
by: CatchSandeepVaid | last post by:
We all know that one-to-one associations are non-lazly fetched but during this fetching the filters are not applied. I debugged hibernate code and found that hibernate finally calls...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.