1*8617a60dSAndroid Build Coastguard Worker#!/bin/bash 2*8617a60dSAndroid Build Coastguard Worker 3*8617a60dSAndroid Build Coastguard Worker# Copyright 2010 The ChromiumOS Authors 4*8617a60dSAndroid Build Coastguard Worker# Use of this source code is governed by a BSD-style license that can be 5*8617a60dSAndroid Build Coastguard Worker# found in the LICENSE file. 6*8617a60dSAndroid Build Coastguard Worker 7*8617a60dSAndroid Build Coastguard Workerif [ $# -ne 1 ]; then 8*8617a60dSAndroid Build Coastguard Worker echo "Usage: $0 <private_key_pem_file>" 9*8617a60dSAndroid Build Coastguard Worker echo "Reads data to sign from stdin, encrypted data is output to stdout" 10*8617a60dSAndroid Build Coastguard Worker exit 1 11*8617a60dSAndroid Build Coastguard Workerfi 12*8617a60dSAndroid Build Coastguard Worker 13*8617a60dSAndroid Build Coastguard Workeropenssl rsautl -sign -inkey "$1" 14