mirror of
https://github.com/AleziaKurdis/overte.git
synced 2025-04-07 04:53:28 +02:00
propertly encode
This commit is contained in:
parent
f7333e90d8
commit
5fe4f35139
1 changed files with 3 additions and 1 deletions
|
@ -7,7 +7,9 @@
|
|||
- (void) confirmCredentials:(NSString*)username :(NSString*)password {
|
||||
|
||||
NSLog(@"web request started");
|
||||
NSString *post = [NSString stringWithFormat:@"grant_type=password&username=%@&password=%@&scope=owner", username, [password stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet symbolCharacterSet]]];
|
||||
NSString *post = [NSString stringWithFormat:@"grant_type=password&username=%@&password=%@&scope=owner",
|
||||
[username stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet alphanumericCharacterSet]],
|
||||
[password stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet alphanumericCharacterSet]]];
|
||||
NSData *postData = [post dataUsingEncoding:NSUTF8StringEncoding];
|
||||
NSString *postLength = [NSString stringWithFormat:@"%ld", (unsigned long)[postData length]];
|
||||
|
||||
|
|
Loading…
Reference in a new issue