Posts

Showing posts from November 18, 2018

How to set login and session to never expire in ASP.Net forms authentication & SQL Server session mode?

Image
up vote 0 down vote favorite We have an existing application on ASP.Net forms & uses SQL Server session state mode with custom database (not tempdb). The application uses forms authentication to login. What we need to do is: once logged in to a particular browser, the login and session never expires. Even after the browser exit or system restarts or there is no user activity. the user need to re-login only after cookies are cleared manually OR as a system administrator we truncate the SQL database tables for session management. How can this be achieved ? c# asp.net session session-cookies forms-authentication share | improve this question asked 2 days ago ...

Public API with authorization token — is it possible to protect the demo token?

Image
up vote 9 down vote favorite 3 I have a REST API for running some calculations and returning the result, with a very simple token system where only authorized users can use the API. The user adds their token to the query like this: { authorization: 'my token', moreData: 51351, etc: 'etc' } Because the users of this API are usually not programmers, I have made a very simple web page demonstrating the API, with a live demo that can be run directly from the web page, demonstrating how it works and what is returned. This demonstration has a fake authorization token, which is displayed in the example query. I have made a simple, hidden and partially obfuscated JavaScript function that intercepts this fake token and replaces it with an actual token before sending the request, which will probably tr...
ZQXR2VTwgwQbbUbQ05Aj,O8HjzF38Gv48v0q8f Ow5lOBDc46s20TlExsCqOB Dd8SIA5Vi u,AMDtH8keY1W3,vjrKG rA