-
Notifications
You must be signed in to change notification settings - Fork 17
/
PEMfileToCString.html
73 lines (72 loc) · 3.8 KB
/
PEMfileToCString.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
<!DOCTYPE html>
<html lang="en">
<head>
<title>FreeRTOS Developer Demos Certificate Configuration Tool</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="js/generator.js"></script>
</head>
<body>
<script>
// Check for the various File API support.
if (window.File && window.FileReader && window.FileList && window.Blob) {
// Success! All the File APIs are supported.
} else {
alert('Please use a web browser that supports HTML5 file APIs.');
}
</script>
<div class="row">
<div class="col-lg-2"></div>
<div class="col-lg-8">
<div class="panel panel-primary">
<div class="panel-heading">
<h2>PEM to C String Conversion Tool</h2>
<h4>Use with FreeRTOS Developer Tests</h4>
</div>
<div class="panel-body">
<div class="container-fluid">
<div class="row">
<div class="col-md-12">
<p class="text-primary" id="header-text" style="font-size:18px">
Select a PEM key or PEM certificate file to be converted into the format required by aws_clientcredential_keys.h
</p>
<div class="panel panel-default">
<div class="panel-body" style="background:#F8F8F8;">
<div class="row">
<div class="col-md-12">
<div class="form-group">
<label for="pemInputFile" style="font-size:16px">
PEM Certificate or Key:
</label>
<input type="file" id="pemInputFile" />
</div>
<button type="button" class="btn btn-primary" style="font-size:16px"
onclick='generatePemTextToDisplay()'>
<span class="glyphicon glyphicon-download"></span>
Display formatted PEM string to be copied into aws_clientcredential_keys.h
</button>
</div>
</div>
</div>
</div>
<p class="text-primary" style="font-size:14px">
<span class="glyphicon glyphicon-warning-sign" style="font-size:16px"></span>
Copy the key or certificate into the appropriate variable in <i>tests/common/include/aws_clientcredential_keys.h</i> file of the test project.
</p>
<p style="font-family: Consolas;">
<span id="pemToDisplay"></span>
</p>
</div>
</div>
</div>
<div class="text-center">
Copyright © 2017 Amazon.com, Inc. or its affiliates. All Rights Reserved.
</div>
</div>
</div>
</div>
<div class="col-lg-2"></div>
</div>
</body>
</html>