在响应身份验证质询时,NSURLCredential是通过https连接发送密码的安全方式吗?我假设这会以一种安全的方式发送用户名和密码。加密的,而不仅仅是url中的参数-这是正确的吗?
感谢您的回复!
发布于 2011-10-07 03:48:25
是的,是的。如果您正确地回答委托方法,则NSURLCredential是安全的。
发布于 2011-10-06 14:58:52
如果您回答委托方法,它将被安全地传递。
- (void)connection:(NSURLConnection *)connection didReceiveAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge {
NSString *user = you user
NSString *password = you pass;
NSURLCredential *credential = [NSURLCredential credentialWithUser:user
password:password
persistence:NSURLCredentialPersistenceForSession];
[[challenge sender] useCredential:credential forAuthenticationChallenge:challenge];
}
https://stackoverflow.com/questions/7675624
复制相似问题