// Saves hash of user's password.
- (void)controlTextDidEndEditing:(NSNotification *)aNotification
{
NSString *password = [[aNotification object] stringValue];
SSCrypto *crypto = [SSCrypto alloc];
[crypto setClearTextWithString:password];
NSString *passwordHash = [[crypto digest:@"MD5"] hexdump];
// Here's where I go astray.
NSManagedObject *user = nil;
user = [NSEntityDescription entityForName:@"User" inManagedObjectContext:
[TestAppDelegate managedObjectContext]];
[user setValue: passwordHash forKey: @"password"];
}
A. Am I getting a reference to the User managed object correctly?