Skip to main content
726 votes
35 answers
2.5m views

I am parsing a string in C++ using the following: using namespace std; string parsed,input="text to be parsed"; stringstream input_stringstream(input); if (getline(input_stringstream,parsed,' ')) { ...
TheCrazyProgrammer's user avatar
569 votes
8 answers
448k views

I want to understand what token-based authentication means. I searched the internet but couldn't find anything understandable.
csharpbaby's user avatar
  • 6,165
345 votes
19 answers
765k views

In my react app i am using axios to perform the REST api requests. But it's unable to send the Authorization header with the request. Here is my code: tokenPayload() { let config = { headers: ...
rakibtg's user avatar
  • 5,961
275 votes
4 answers
250k views

I'm learning something about Authorization like Basic, Digest, OAuth2.0, JWTs, and Bearer Token. JWTs are used as an Access_Token in the OAuth2.0 standard. JWTs appears at RFC 7519, and Bearer Token ...
laoqiren's user avatar
  • 3,977
242 votes
25 answers
145k views

I was using a username password for pushing my code. It was working for several months, but suddenly I'm not able to do it and am getting this error: Username for 'https://github.com': shreyas-jadhav ...
Shreyas Jadhav's user avatar
211 votes
3 answers
64k views

From what I've learned so far, the purpose of tokens is to prevent an attacker from forging a form submission. For example, if a website had a form that input added items to your shopping cart, and ...
php_learner's user avatar
  • 2,119
183 votes
3 answers
90k views

I am trying to write a program where the names of some functions are dependent on the value of a certain macro variable with a macro like this: #define VARIABLE 3 #define NAME(fun) fun ## _ ## ...
JJ.'s user avatar
  • 1,831
177 votes
4 answers
202k views

How can I authenticate a socket.io connection? My application uses a login endpoint from another server (python) to get a token, how can I get use that token whenever a user opens a socket connection ...
el_pup_le's user avatar
  • 12.2k
176 votes
13 answers
168k views

I have used the refresh token several times in just a short period for testing purposes, but I wonder whether Google refresh tokens ever expire? Can I use the same refresh token to get another access ...
Robin Carlo Catacutan's user avatar
166 votes
9 answers
459k views

I have a request URI and a token. If I use: curl -s "<MY_URI>" -H "Authorization: TOK:<MY_TOKEN>" etc., I get a 200 and view the corresponding JSON data. So, I installed requests and when ...
user avatar
159 votes
7 answers
172k views

My SPA application uses the following architecture (source): This assumes that my client application knows about the refresh token, because I need it to request a new access token if no user ...
Robin Wieruch's user avatar
151 votes
6 answers
109k views

I am going to use oAuth to fetch mails and contacts from google. I don't want to ask the user each time to log in to obtain an access token and secret. From what I understood, I need to store them ...
yeahman's user avatar
  • 2,777
144 votes
2 answers
194k views

I generated a JWT and there are some claims which I understand well, but there is a claim called kid in header. Does anyone know what it means? I generated the token using auth0.com
tylkonachwile's user avatar
138 votes
16 answers
440k views

Please explain to me the working of strtok() function. The manual says it breaks the string into tokens. I am unable to understand from the manual what it actually does. I added watches on str and *...
user avatar
132 votes
2 answers
79k views

I want to create a C macro that creates a function with a name based on the line number. I thought I could do something like (the real function would have statements within the braces): #define UNIQUE ...
DD.'s user avatar
  • 1,323

15 30 50 per page
1
2 3 4 5
512