14 messaggi dal 13 marzo 2018
Salve,

ho cantato vittoria troppo presto.
Il mio sito ha una piccola applicazione di calcolo in cui l'utente può inserire un proprio file. Inserendo il file sul sito caricato correttamente su register.it è tutto ok; riprovo dopo un secondo ad inserire il file e mi compare:

Server Error in '/' Application.
Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster.

See http://go.microsoft.com/fwlink/?LinkID=314055 for more information.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Web.HttpException: Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster.

See http://go.microsoft.com/fwlink/?LinkID=314055 for more information.

Source Error:

The source code that generated this unhandled exception can only be shown when compiled in debug mode. To enable this, please follow one of the below steps, then request the URL:

1. Add a "Debug=true" directive at the top of the file that generated the error. Example:

<%@ Page Language="C#" Debug="true" %>

or:

2) Add the following section to the configuration file of your application:

<configuration>
<system.web>
<compilation debug="true"/>
</system.web>
</configuration>

Note that this second technique will cause all files within a given application to be compiled in debug mode. The first technique will cause only that particular file to be compiled in debug mode.

Important: Running applications in debug mode does incur a memory/performance overhead. You should make sure that an application has debugging disabled before deploying into production scenario.

Stack Trace:


[ViewStateException: Invalid viewstate.
Client IP: xxx.xxx.xx.xx
Port: xxxx
http://nomesito
Path: /xxxxxx
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.139 Safari/537.36
ViewState: cnj5Q+agUqDIgA0JFeywWxWbnPHX3LxTTBE/5iFZBMQOxs7F2gcrcCoGuRBPdREYX2r7Lj5ggzMNksD/EoH3KaiyJvwbvdsEz14ccnX/Fsc4bazt0NVZdaEExAOZRky75QUIsTmfJiMU6Wmk/ysvGPdB7rFZlaz7IFG6f3Fts4Sx6V4Pk+m41fiOJcNxzxjDWGiZLkTWnfi+vsuNXVSKVF7cNjzVyd93PNrXc76G5Ept2FD2VjUxU7cZHut7qBKx2ZTBbJQa73Rp+87+d9xt0yWOI32o0B5nl7QgumV1lSOmLfakXyerQUbDPnBSDxOKYP7HfFZV5gro8ULNh57L1t0qHQB9wCol62DZ8aTFbmJwHmWyWHk7+RYMhxVOqbiE+nfpDJ75U1CL+6c9HSC+l9npeKF8VbHtoo+WfxjmIhoN6XUXeGfekb8TxvHbHdSM]

[HttpException (0x80004005): Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster.

See http://go.microsoft.com/fwlink/?LinkID=314055 for more information.]
System.Web.UI.ViewStateException.ThrowError(Exception inner, String persistedState, String errorPageMessage, Boolean macValidationError) +116
System.Web.UI.ObjectStateFormatter.Deserialize(String inputString, Purpose purpose) +425
System.Web.UI.ObjectStateFormatter.System.Web.UI.IStateFormatter2.Deserialize(String serializedState, Purpose purpose) +13
System.Web.UI.Util.DeserializeWithAssert(IStateFormatter2 formatter, String serializedState, Purpose purpose) +40
System.Web.UI.HiddenFieldPageStatePersister.Load() +248
System.Web.UI.Page.LoadPageStateFromPersistenceMedium() +251
System.Web.UI.Page.LoadAllState() +36
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +6712
System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +245
System.Web.UI.Page.ProcessRequest() +72
System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context) +22
System.Web.UI.Page.ProcessRequest(HttpContext context) +58
ASP.preventivatore_aspx.ProcessRequest(HttpContext context) +4
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +188
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +69


Caricando lo stesso sito su Somee (versione gratuita) va sempre tutto bene.
Suggerimenti?

grazie mille, a presto
Ron

Torna al forum | Feed RSS

ASPItalia.com non è responsabile per il contenuto dei messaggi presenti su questo servizio, non avendo nessun controllo sui messaggi postati nei propri forum, che rappresentano l'espressione del pensiero degli autori.