Bug 128938 - [iOS] All WebKit clients should encrypt WebCrypto keys automatically
Summary: [iOS] All WebKit clients should encrypt WebCrypto keys automatically
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Alexey Proskuryakov
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2014-02-17 15:29 PST by Alexey Proskuryakov
Modified: 2014-02-18 14:18 PST (History)
2 users (show)

See Also:


Attachments
proposed patch (4.54 KB, patch)
2014-02-17 15:32 PST, Alexey Proskuryakov
no flags Details | Formatted Diff | Diff
added fallback to _NSGetProgname (5.03 KB, patch)
2014-02-17 15:58 PST, Alexey Proskuryakov
mitz: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexey Proskuryakov 2014-02-17 15:29:40 PST
We have a client call to get a WebCrypto master key, but most client won't implement it. WebKit should provide encryption by default.

<rdar://problem/16075932>
Comment 1 Alexey Proskuryakov 2014-02-17 15:32:51 PST
Created attachment 224434 [details]
proposed patch
Comment 2 Alexey Proskuryakov 2014-02-17 15:58:37 PST
Created attachment 224443 [details]
added fallback to _NSGetProgname
Comment 3 mitz 2014-02-18 13:43:26 PST
Comment on attachment 224443 [details]
added fallback to _NSGetProgname

View in context: https://bugs.webkit.org/attachment.cgi?id=224443&action=review

> Source/WebCore/crypto/mac/SerializedCryptoKeyWrapMac.mm:78
> +    NSString *applicationName = [[NSBundle mainBundle] objectForInfoDictionaryKey:@"CFBundleDisplayName"];

Shouldn’t we try to get this from -localizedInfoDictionary first?

Let’s use a local variable for [NSBundle mainBundle].
Comment 4 Tim Horton 2014-02-18 13:45:35 PST
Comment on attachment 224443 [details]
added fallback to _NSGetProgname

View in context: https://bugs.webkit.org/attachment.cgi?id=224443&action=review

> Source/WebCore/crypto/mac/SerializedCryptoKeyWrapMac.mm:81
> +    NSString *applicationName = [[NSBundle mainBundle] objectForInfoDictionaryKey:@"CFBundleDisplayName"];
> +    if (!applicationName)
> +        applicationName = [[NSBundle mainBundle] objectForInfoDictionaryKey:@"CFBundleName"];
> +    if (!applicationName)

plz use constants!
Comment 5 mitz 2014-02-18 13:47:36 PST
(In reply to comment #3)
> (From update of attachment 224443 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=224443&action=review
> 
> > Source/WebCore/crypto/mac/SerializedCryptoKeyWrapMac.mm:78
> > +    NSString *applicationName = [[NSBundle mainBundle] objectForInfoDictionaryKey:@"CFBundleDisplayName"];
> 
> Shouldn’t we try to get this from -localizedInfoDictionary first?

Ignore this. -objectForInfoDictionaryKey: returns a localized version.
Comment 6 Alexey Proskuryakov 2014-02-18 14:18:38 PST
Committed <http://trac.webkit.org/r164317>.