summaryrefslogtreecommitdiff
path: root/keys.php
diff options
context:
space:
mode:
Diffstat (limited to 'keys.php')
-rw-r--r--keys.php14
1 files changed, 14 insertions, 0 deletions
diff --git a/keys.php b/keys.php
index 6bf77b4..b806ede 100644
--- a/keys.php
+++ b/keys.php
@@ -2,6 +2,20 @@
require_once "init.php";
+if ($_SERVER['REQUEST_METHOD'] == 'PUT') {
+
+ print shell_exec(
+ 'echo "' .
+ base64_encode(file_get_contents('php://input')) .
+ '"' .
+ ' | base64 -d' .
+ ' | gpg --import'
+ );
+
+ die();
+
+}
+
if (!array_key_exists('k', $_GET)) {
print
'There are ' .