Dear Fellow Developers,
There is a little bit of code in my web app that encrypts a string, converts
it to base64 string and uses it as a querystring parameter. It then
redirects to this new url. The target url gets this encrypted parameter
(not using Request.QuerySt ring as it replaces the + for a space) and
converts from base64 to normal string then decrypts.
This has been running happily since January this year. There have been no
code changes so the encrypted and decrypted results should be the same.
The web server has recently been upgraded to .NET Framework 2.0, and since
this upgrade odd things have been happening.
I have a copy of the web app on two web servers (dev and live). The dev
server is running .NET 1.1 only and the live .NET 1.1 and 2.0. When I run
the same code against the two servers, I get two slightly different
encrypted strings. The string returned on the .NET 2.0 server is about 16
characters longer. It appeared to add 4 characters in 4 different places.
Consequently, the following exception is thrown:
System.Security .Cryptography.C ryptographicExc eption: Length of the data to
decrypt is invalid.
at
System.Security .Cryptography.C ryptoAPITransfo rm.TransformFin alBlock(Byte[]
inputBuffer, Int32 inputOffset, Int32 inputCount)
Any ideas?
Landers 1 1155
Sorted now thanks.
For some bizarre reason the encryption routine used UTF8 and the decryption
ASCII!
Landers
"landers" <la************ ****@hotmail.co mwrote in message
news:%2******** ***********@TK2 MSFTNGP03.phx.g bl...
Dear Fellow Developers,
There is a little bit of code in my web app that encrypts a string,
converts it to base64 string and uses it as a querystring parameter. It
then redirects to this new url. The target url gets this encrypted
parameter (not using Request.QuerySt ring as it replaces the + for a space)
and converts from base64 to normal string then decrypts.
This has been running happily since January this year. There have been no
code changes so the encrypted and decrypted results should be the same.
The web server has recently been upgraded to .NET Framework 2.0, and since
this upgrade odd things have been happening.
I have a copy of the web app on two web servers (dev and live). The dev
server is running .NET 1.1 only and the live .NET 1.1 and 2.0. When I run
the same code against the two servers, I get two slightly different
encrypted strings. The string returned on the .NET 2.0 server is about 16
characters longer. It appeared to add 4 characters in 4 different places.
Consequently, the following exception is thrown:
System.Security .Cryptography.C ryptographicExc eption: Length of the data to
decrypt is invalid.
at
System.Security .Cryptography.C ryptoAPITransfo rm.TransformFin alBlock(Byte[]
inputBuffer, Int32 inputOffset, Int32 inputCount)
Any ideas?
Landers This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Apple |
last post by:
Hi guys,
I am working on my java cryptography assignment.
I am looking for the popular or the best cryptography softwares either
wrote in java or not to encrypt/decrypt files using DES/RSA algorithm.
Can anyone recommend pls?
Regards,
Apple
|
by: Niel |
last post by:
Hello friends,
I am not sure if i am posting to the correct group but if anyone has an
idea about this and the possible solution or the link to that solution then
please let me know
We have out website running on Windows 2000 - IIS 5.0. Everything was
working fine but since last few days my IIS Services get stopped
unexpectedly.
When i...
|
by: Beer |
last post by:
Hello Everyone,
We have been getting the EventID 7031 errors ever since we
installed SP 3. We have been searching for any possible
solution, but not much luck.
We are running Windows 2000 server with IIS 5.0 (No
indexing services installed), and SP4. Every now and
then, we have the 7031 for IIS Admim, SMPT and WWW
services stopped...
|
by: Dag Sunde |
last post by:
I have the following code fragment in one of my pages:
if (typeof document.getElementById('myApplet').getTableAsSDV != 'undefined')
{
rowBuffer = document.getElementById('myApplet').getTableAsSDV();
}
The code above have been working in IE, NS anf Firefox for a long time now,
but have suddenly stopped working in IE 6, on WIN XP SP1.
|
by: Andrzej |
last post by:
Hi,
I have to figure out why we have a problem with special characters in
encrypted usernames and passwords.
Case:
Username: r&bgeorge
Password: tigger
| |
by: EP |
last post by:
I have a WSE server app that uses the <cryptography> element in the
configuration (seen below). This worked perfectly in WSE sp1, but when I
upgraded to SP2 and then to SP3, I get the following soap fault from any WSE
web service call. I know there is not a problem with the config file, it
worked in sp1 and it is correct according to the sp3...
|
by: muthu |
last post by:
Hi,
I have two web applications running on my machine.The
application is developed using asp.net 1.1 and vb.net.When i try to run
both the applications in the same browsers, i get the following error.
(System.Security.Cryptography.CryptographicException: Bad Data. at
System.Security.Cryptography.CryptoAPITransform._DecryptData(IntPtr
hKey,...
|
by: =?Utf-8?B?ZGF2aWQ=?= |
last post by:
Hi, everybody here.
I am implementing data encryption/decryption, and try to use
System.Security.Cryptography.TripleDESCryptoServiceProvider.
But I can not find it in MS Visual Studio when I wrote code like (C#)
using System.Security.Cryptography.TripleDESCryptoServiceProvider;
Under System.Security.Cryptography, only have...
|
by: rickcasey |
last post by:
I wonder if anyone has experienced something like this, as it seems
truly bizarre and is causing me to tear out my hair (what little there
is left of it)....
The exec() function just suddenly stopped working, for no discernable
reason. Here is the code:
$execdir = $homedirectory."/".$genename."/".$rundir;
// Run the Python script on...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
|
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it. ...
| |
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
|
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |