Invalid length for a Base-64 char array

10 posts, 0 answers
  1. Alessandro
    Alessandro avatar
    20 posts
    Member since:
    Sep 2011

    Posted 04 Mar 2013 Link to this post

    Hi,


    we're experiencing many times the error "Invalid length for a Base-64 char array". This error is written by our web site (not web application) by the AsyncPostBackError event handler of the RadScriptManager. We've got log information for this error 50/100 times a day.
    We asked to the users if they see the error during navigation through pages, but only sometimes happens. In case that they see this mistake, there is a situation wherein the user clicks on a button (that is inside a form with many refresh panel, like a web email-send form, but whose fields require single validation on entry,e.g. for the Italian tax code which is calculated on the basis of the personal data) but the refresh panel starts the postback without the refresh image (also the IE loading with the refresh image inside the tab title isn't visible). So the user click multiple times on the  button and only after three or four times sees the correct refresh visualization or the render result on the browser page.

    We have an error page, that is redirected by the AsyncPostbackError handler of the master page in case of error and there is a case, always on this page, wherein the user writes some data in the entries and uses option field to change the visualization, e.g. to pass to the societies data entry form, and we have log entry for errors during this navigation that comes from event handler that I mentioned and from Error page, but the user neither see the error in the web browser and the navigation never gone to the error page, but remains on the same page. This is a very strange situation, and we ask you how is possible...

    Which is the cause of this error? 

    We don't use any compression or other functionality on the viewstate or on ajax requests. We can observe this error only on few pages like this one I was talking about above.

    The website run over a framework 4.0 pool. We use the 2012.3.1308.40 telerik reference of 2013 q1.

    thanks in advance, I hope the post is complete and understandable.
    we look forward for your feedback
    best regards

    Emanuele
    M&GF Project 
  2. Martin
    Admin
    Martin avatar
    811 posts

    Posted 07 Mar 2013 Link to this post

    Hello Emanuele,

    I suspect that the problem might be caused by in issue with RadCompression that we introduced in Q1 2013 release (2013.1.220). To verify whether this is the case, please disable RadCompression in your application. More information about RadCompression is available here.

    Kind regards,
    Martin
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Alessandro
    Alessandro avatar
    20 posts
    Member since:
    Sep 2011

    Posted 07 Mar 2013 Link to this post

    Hello Martin,

    we haven't any compression activated. Is it automatically activated?


    thanks,
    Emanuele


  5. Martin
    Admin
    Martin avatar
    811 posts

    Posted 07 Mar 2013 Link to this post

    Hello Emanuele,

    To verify whether RadCompression is enabled, please look in the web.config file of your project for the following lines:

    <httpmodules>
        ...
        <!-- Add this line exactly as is - the name value is important -->
        <add name="RadCompression" type="Telerik.Web.UI.RadCompression" />
    </httpmodules>
    <!-- If you're using IIS7, then add this, too-->
    <system.webserver>
     <modules>
       ...
       <add name="RadCompression" type="Telerik.Web.UI.RadCompression" />
     </modules>
    ...    
    </system.webserver>

    In case you find it, please remove the highlighted lines above.

    Regards,
    Martin
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  6. Alessandro
    Alessandro avatar
    20 posts
    Member since:
    Sep 2011

    Posted 08 Mar 2013 Link to this post


    hello,

    I verified that we haven't any reference to radcompression registered in web.config inside the two section that you described and there is no registration written in the config file. Any suggestions?


    best regards
    Emanuele
  7. Martin
    Admin
    Martin avatar
    811 posts

    Posted 08 Mar 2013 Link to this post

    Hello Emanuele,

    Since RadCompression is not involved, I can only guess what may be the cause of the issue. I would suggest that you temporarily disable AJAX functionality and verify whether the problem continues to replicate. I would also need the exact exception message because it provides valuable information about the error itself. Another approach you can follow is to try to assemble a stripped runnable version of your website that replicates the issue. This way I would be able to debug it locally and provide more to the point resolution.

    All the best,
    Martin
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  8. Alessandro
    Alessandro avatar
    20 posts
    Member since:
    Sep 2011

    Posted 08 Mar 2013 Link to this post


    Hi,

    here is the information we have about this error (it's written by the AsyncPostBackError event handler of the RadScriptManager) this is the ex.message :

    Invalid length for a Base-64 char array
    . in System.Convert.FromBase64String(String s) in System.Web.UI.ObjectStateFormatter.Deserialize(String inputString) in System.Web.UI.ObjectStateFormatter.System.Web.UI.IStateFormatter.Deserialize(String serializedState) in System.Web.UI.Util.DeserializeWithAssert(IStateFormatter formatter, String serializedState) in System.Web.UI.HiddenFieldPageStatePersister.Load() 

    we can't do a stripped runnable version for you because it's a very heavy web site too complex and varied to be thinned, and the source code is a property of a client.


    thanks

    Emanuele
  9. Martin
    Admin
    Martin avatar
    811 posts

    Posted 11 Mar 2013 Link to this post

    Hello Emanuele,

    I have reviewed the stack trace, however I do not see any reference to Telerik code. The only thing that comes into my mind and might be related to this error is the viewstate compression feature of RadCompression. Could you please verify that viewstate compression is not enabled for your site (it is turned on by a .browser file. For more information go to the ViewState compression section here)?

    All the best,
    Martin
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  10. ABC
    ABC avatar
    20 posts
    Member since:
    Mar 2012

    Posted 01 Oct 2013 Link to this post

    I am also getting the same error intermittently, again and again. My RadCompression is enabled. Shoud I disable it. My version is 2012.2.912.40
  11. Antonio Stoilkov
    Admin
    Antonio Stoilkov avatar
    530 posts

    Posted 04 Oct 2013 Link to this post

    Hello,

    You could try disabling the RadCompression in order to resolve your issue as suggested by Martin. However, without replicating the problem on our side and debugging it there is no way to say for sure what is causing the experienced exception.

    Regards,
    Antonio Stoilkov
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017