[Webkit-unassigned] [Bug 148439] cryptographicallyRandomValuesFromOS should use CCRandomCopyBytes when available.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Aug 25 16:12:42 PDT 2015


Alexey Proskuryakov <ap at webkit.org> changed:

           What    |Removed                     |Added
 Attachment #259880|review?, commit-queue?      |review-, commit-queue-
              Flags|                            |

--- Comment #12 from Alexey Proskuryakov <ap at webkit.org> ---
Comment on attachment 259880
  --> https://bugs.webkit.org/attachment.cgi?id=259880

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

> Source/WTF/wtf/Assertions.h:51
> +#include <os/trace.h>

is this what breaks iOS build?

/Volumes/Data/EWS/WebKit/WebKitBuild/Release-iphoneos/usr/local/include/wtf/spi/darwin/XPCSPI.h:37:1: error: typedef redefinition with different types ('NSObject<OS_xpc_object> *' vs 'void *')

> Source/WTF/wtf/OSRandomSource.cpp:33
> +#if __has_include(<CommonCrypto/CommonRandomSPI.h>)

This check will fail for open source WebKit builds (including nightlies), because CommonRandomSPI.h is an internal header.

In WebCore, we declare it in crypto/CommonCryptoUtilities.h - or you could add a CommonCryptoSPI header in WTF.

> Source/WTF/wtf/OSRandomSource.cpp:72
> +    if (result != kCCSuccess)
> +        CRASH_WITH_MESSAGE("crytographicallyRandomValuesFromOS could not get cryptographically random information from CCRandomCopyBytes and had error: %d", result);

I'm not sure how this is more helpful than a simple RELEASE_ASSERT. We can see where that one happens, and CCRandomCopyBytes can't fail anyway.

You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20150825/968e3e75/attachment-0001.html>

More information about the webkit-unassigned mailing list