Search - Articles
DevASP.NET for ASP.NET, VB.NET, XML and C# (C-Sharp) Developers Wednesday, October 18, 2017

Dev Articles
Search Directory
ASP.NET
VB.Net
C-Sharp
SQL Server
 


Home > Search > Knowledge Base > ASP.Net > Errors and Bugs > ASP.NET Bugs
Error When You Use 3DES Encryption with Manual Keys in Web.config file of ASP.NET Application (Q317054)        
Total Hits: 146  |  Today: 0 Author: MSDN       Rating:  
Read Reviews | Write Review | Your Rating: 

When you use the 3DES encryption type for the validation attribute of the tag in the Web.config file for the application, if you specify a manual key for the validationKey and the decryptionKey attributes, you receive the following error message when you browse to .aspx pages on the application:

Server Error in '/WebApplication1' Application.

Offset and length were out of bounds for the array or count is greater than the number of elements from index to the end of the source collection

Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:
[ArgumentException: Offset and length were out of bounds for the array or count is greater than the number of elements from index to the end of the source collection.]
System.Buffer.BlockCopy(Array src, Int32 srcOffset, Array dst, Int32 dstOffset, Int32 count) +0
System.Web.Configuration.MachineKey.GetEncodedData(Byte[] buf, String strModifier, Int32 start, Int32 length) +716
System.Web.UI.LosWriter.CompleteTransforms(TextWriter output, Boolean enableMac, String macKey) +187
System.Web.UI.LosFormatter.SerializeInternal(TextWriter output, Object value) +122
System.Web.UI.Page.OnFormRender(HtmlTextWriter writer, String formUniqueID) +143
System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer) +35
System.Web.UI.HtmlControls.HtmlForm.Render(HtmlTextWriter output) +395
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +243
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +72
System.Web.UI.Control.Render(HtmlTextWriter writer) +7
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +243
System.Web.UI.Page.ProcessRequestMain() +1900


What's New at DevASP.Net
04/23  A Debug Stopwatch
04/23  The virtual bool bug
04/23  Application.EnableVisualStyles Bu..
04/23  The Process Async Reader Bug
04/23  Load a DBF into a DataTable
04/23  Weird Error: Unable to Validate D..
04/23  ASP.NET and jQuery to the Max
04/23  Fixing Error: "SetConfigurationSe..
04/23  Generics in .NET
04/23  Builder Design Pattern
04/23  Abstract Factory Design Pattern
04/23  Prototype Design Pattern
04/23  Bridge Design Pattern
04/23  Composite Design Pattern
04/23  Decorator Design Pattern
04/23  Validation in .NET Framework 4
04/23  Windows Phone 7: How to Encrypt C..
04/23  Text box to accept only number
04/23  Using the Raw Input API to Proces..
04/23  Study EVM (Earned Value Managemen..

DevASP.Net - Disclaimer - Privacy
2002-2010 DevASP.net