Add example binary for testing building the SDK after 'git clone' from our repo. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=227583629
35 lines
1.3 KiB
C++
35 lines
1.3 KiB
C++
////////////////////////////////////////////////////////////////////////////////
|
|
// Copyright 2018 Google LLC.
|
|
//
|
|
// This software is licensed under the terms defined in the Widevine Master
|
|
// License Agreement. For a copy of this agreement, please contact
|
|
// widevine-licensing@google.com.
|
|
////////////////////////////////////////////////////////////////////////////////
|
|
|
|
#ifndef COMMON_SIGNATURE_UTIL_H_
|
|
#define COMMON_SIGNATURE_UTIL_H_
|
|
|
|
#include <string>
|
|
|
|
#include "common/status.h"
|
|
|
|
namespace widevine {
|
|
namespace signature_util {
|
|
|
|
// Generates an AES signature of |message| using |aes_key| and |aes_iv|.
|
|
// Signature is returned via |signature| if generation was successful.
|
|
// Returns a Status that carries the details of error if generation failed.
|
|
Status GenerateAesSignature(const std::string& message, const std::string& aes_key,
|
|
const std::string& aes_iv, std::string* signature);
|
|
|
|
// Generates a RSA signature of |message| using |private_key|.
|
|
// Signature is returned via |sigature| if generation was successful.
|
|
// Returns a Status that carries the details of error if generation failed.
|
|
Status GenerateRsaSignature(const std::string& message, const std::string& private_key,
|
|
std::string* signature);
|
|
|
|
} // namespace signature_util
|
|
} // namespace widevine
|
|
|
|
#endif // COMMON_SIGNATURE_UTIL_H_
|