summaryrefslogtreecommitdiff
path: root/create-token
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2018-04-24 17:03:17 +0300
committerLars Wirzenius <liw@liw.fi>2018-04-25 19:07:44 +0300
commit224afe3b367cba9b978115e969e714c14c71caa6 (patch)
tree89f578874c9e75b6ebb93f46f5ecddfb8d94adf0 /create-token
parentdf60c28287900478ced251123c9887e61e0dc17c (diff)
downloadick2-224afe3b367cba9b978115e969e714c14c71caa6.tar.gz
Change: GET /work, POST /worker use access token to identify worker
Diffstat (limited to 'create-token')
-rwxr-xr-xcreate-token4
1 files changed, 2 insertions, 2 deletions
diff --git a/create-token b/create-token
index a99b611..55a7f7e 100755
--- a/create-token
+++ b/create-token
@@ -1,5 +1,5 @@
#!/usr/bin/python3
-# Copyright (C) 2017 Lars Wirzenius
+# Copyright (C) 2017-2018 Lars Wirzenius
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
@@ -26,13 +26,13 @@ import apifw
# FIXME: These should agree with how ick controller is configured.
# See the Ansible playbook.
iss = 'localhost'
-aud = 'localhost'
key_text = sys.stdin.read()
key = Crypto.PublicKey.RSA.importKey(key_text)
scopes = ' '.join(sys.argv[1].split())
+aud = sys.argv[2]
now = time.time()
claims = {