blob: a4623fea50cb98c9e1f3acc76226a644c4ef88dd [file] [log] [blame]
// Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
#include "platform/globals.h"
#include "bin/crypto.h"
#include <zircon/syscalls.h>
namespace dart {
namespace bin {
bool Crypto::GetRandomBytes(intptr_t count, uint8_t* buffer) {
zx_cprng_draw(buffer, count);
return true;
} // namespace bin
} // namespace dart
#endif // defined(DART_HOST_OS_FUCHSIA)