RadAsyncUpload and CSRF token

4 posts, 1 answers
  1. Dawid
    Dawid avatar
    6 posts
    Member since:
    Jan 2012

    Posted 04 Jul 2013 Link to this post

    I'm using RadAsyncUpload to allow a file to be uploaded to the server.

    However, we also have an anti-CSRF token on the page involved.  Is there some way that I can append a header or add to the request that AsyncUpload makes to enable this to be passed along?

    Thanks.
  2. Hristo Valyavicharski
    Admin
    Hristo Valyavicharski avatar
    975 posts

    Posted 09 Jul 2013 Link to this post

    Hi Dawid,

    At the moment RadAsyncUpload does not expose API, that allow you to modify header of the request. Are you using this library - AntiCSRF? We need this information in order to make a deeper research with our code base and try to provide you an example that could solve your case.

    Regards,
    Hristo Valyavicharski
    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.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Dawid
    Dawid avatar
    6 posts
    Member since:
    Jan 2012

    Posted 09 Jul 2013 Link to this post

    Hi Hristo,

    That is indeed the library that I was using.  But even if I had to create the token and handle it without that module, it would be really useful.

    Thanks.
  5. Answer
    Hristo Valyavicharski
    Admin
    Hristo Valyavicharski avatar
    975 posts

    Posted 15 Jul 2013 Link to this post

    Hi Dawid,

    It seems that RadAsyncUpload works correctly when Custom Handler is used. There is no  need to make any additional settings. Please find the attached sample. I have tested it on IIS7.5 and ASP.NET v4.0 Classic as an Application Pool.

    Regards,
    Hristo Valyavicharski
    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