summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdam Misnyovszki <amisnyov@redhat.com>2014-05-07 15:10:32 +0200
committerPetr Vobornik <pvoborni@redhat.com>2014-05-07 16:55:01 +0200
commit1ef91701e984c5c9717803a0d3c2e52c81386676 (patch)
tree3c65a68f43e732980b2472fd43f628ea5acd91db
parent86ff28fac8fdb81386ae0b84f352e3b2e8f5a396 (diff)
downloadfreeipa-1ef91701e984c5c9717803a0d3c2e52c81386676.tar.gz
freeipa-1ef91701e984c5c9717803a0d3c2e52c81386676.tar.xz
freeipa-1ef91701e984c5c9717803a0d3c2e52c81386676.zip
webui OTP token test data added
Reviewed-By: Petr Vobornik <pvoborni@redhat.com>
-rw-r--r--install/ui/test/data/otptoken_add.json43
-rw-r--r--install/ui/test/data/otptoken_batch_del.json27
-rw-r--r--install/ui/test/data/otptoken_batch_mod.json34
-rw-r--r--install/ui/test/data/otptoken_find_pkeys.json17
-rw-r--r--install/ui/test/data/otptoken_get_records.json57
-rw-r--r--install/ui/test/data/otptoken_mod.json72
-rw-r--r--install/ui/test/data/otptoken_show.json51
7 files changed, 301 insertions, 0 deletions
diff --git a/install/ui/test/data/otptoken_add.json b/install/ui/test/data/otptoken_add.json
new file mode 100644
index 000000000..c52fc1503
--- /dev/null
+++ b/install/ui/test/data/otptoken_add.json
@@ -0,0 +1,43 @@
+{
+ "error": null,
+ "id": null,
+ "result": {
+ "result": {
+ "dn": "ipatokenuniqueid=10bd43b5-3204-4695-9225-91064f6c77b3,cn=otp,dc=example,dc=com",
+ "ipatokenmodel": [
+ "totp"
+ ],
+ "ipatokenotpalgorithm": [
+ "sha1"
+ ],
+ "ipatokenotpdigits": [
+ "6"
+ ],
+ "ipatokenotpkey": [
+ {
+ "__base64__": "2TUYXOVTaZf/Og=="
+ }
+ ],
+ "ipatokentotpclockoffset": [
+ "0"
+ ],
+ "ipatokentotptimestep": [
+ "30"
+ ],
+ "ipatokenuniqueid": [
+ "footoken"
+ ],
+ "ipatokenvendor": [
+ "FreeIPA"
+ ],
+ "objectclass": [
+ "top",
+ "ipatokentotp",
+ "ipatoken"
+ ],
+ "uri": "otpauth://totp/EXAMPLE.COM:10bd43b5-3204-4695-9225-91064f6c77b3?digits=6&secret=3E2RQXHFKNUZP7Z2&period=30&algorithm=sha1&issuer=EXAMPLE.COM"
+ },
+ "summary": "Added OTP token \"10bd43b5-3204-4695-9225-91064f6c77b3\"",
+ "value": "10bd43b5-3204-4695-9225-91064f6c77b3"
+ }
+}
diff --git a/install/ui/test/data/otptoken_batch_del.json b/install/ui/test/data/otptoken_batch_del.json
new file mode 100644
index 000000000..7fff0a0c5
--- /dev/null
+++ b/install/ui/test/data/otptoken_batch_del.json
@@ -0,0 +1,27 @@
+{
+ "error": null,
+ "id": null,
+ "result": {
+ "count": 1,
+ "messages": [
+ {
+ "code": 13001,
+ "message": "API Version number was not sent, forward compatibility not guaranteed. Assuming server's API version, 2.83",
+ "name": "VersionMissing",
+ "type": "warning"
+ }
+ ],
+ "results": [
+ {
+ "error": null,
+ "result": {
+ "failed": []
+ },
+ "summary": "Deleted OTP token \"10bd43b5-3204-4695-9225-91064f6c77b3\"",
+ "value": [
+ "10bd43b5-3204-4695-9225-91064f6c77b3"
+ ]
+ }
+ ]
+ }
+}
diff --git a/install/ui/test/data/otptoken_batch_mod.json b/install/ui/test/data/otptoken_batch_mod.json
new file mode 100644
index 000000000..63b99b684
--- /dev/null
+++ b/install/ui/test/data/otptoken_batch_mod.json
@@ -0,0 +1,34 @@
+{
+ "error": null,
+ "id": null,
+ "result": {
+ "count": 1,
+ "results": [
+ {
+ "error": null,
+ "result": {
+ "description": [
+ "Description"
+ ],
+ "ipatokendisabled": [
+ "FALSE"
+ ],
+ "ipatokenmodel": [
+ "totp"
+ ],
+ "ipatokenowner": [
+ "admin"
+ ],
+ "ipatokenuniqueid": [
+ "10bd43b5-3204-4695-9225-91064f6c77b3"
+ ],
+ "ipatokenvendor": [
+ "FreeIPA"
+ ]
+ },
+ "summary": "Modified OTP token \"10bd43b5-3204-4695-9225-91064f6c77b3\"",
+ "value": "10bd43b5-3204-4695-9225-91064f6c77b3"
+ }
+ ]
+ }
+} \ No newline at end of file
diff --git a/install/ui/test/data/otptoken_find_pkeys.json b/install/ui/test/data/otptoken_find_pkeys.json
new file mode 100644
index 000000000..5b7d788a1
--- /dev/null
+++ b/install/ui/test/data/otptoken_find_pkeys.json
@@ -0,0 +1,17 @@
+{
+ "error": null,
+ "id": null,
+ "result": {
+ "count": 1,
+ "result": [
+ {
+ "dn": "ipatokenuniqueid=10bd43b5-3204-4695-9225-91064f6c77b3,cn=otp,dc=example,dc=com",
+ "ipatokenuniqueid": [
+ "10bd43b5-3204-4695-9225-91064f6c77b3"
+ ]
+ }
+ ],
+ "summary": "1 OTP token matched",
+ "truncated": false
+ }
+} \ No newline at end of file
diff --git a/install/ui/test/data/otptoken_get_records.json b/install/ui/test/data/otptoken_get_records.json
new file mode 100644
index 000000000..b3e746db5
--- /dev/null
+++ b/install/ui/test/data/otptoken_get_records.json
@@ -0,0 +1,57 @@
+{
+ "error": null,
+ "id": null,
+ "result": {
+ "count": 1,
+ "results": [
+ {
+ "error": null,
+ "result": {
+ "description": [
+ "Description"
+ ],
+ "dn": "ipatokenuniqueid=10bd43b5-3204-4695-9225-91064f6c77b3,cn=otp,dc=example,dc=com",
+ "ipatokendisabled": [
+ "TRUE"
+ ],
+ "ipatokenmodel": [
+ "totp"
+ ],
+ "ipatokenotpalgorithm": [
+ "sha1"
+ ],
+ "ipatokenotpdigits": [
+ "6"
+ ],
+ "ipatokenotpkey": [
+ {
+ "__base64__": "++R6gVcVPHzz3Q=="
+ }
+ ],
+ "ipatokenowner": [
+ "admin"
+ ],
+ "ipatokentotpclockoffset": [
+ "0"
+ ],
+ "ipatokentotptimestep": [
+ "30"
+ ],
+ "ipatokenuniqueid": [
+ "10bd43b5-3204-4695-9225-91064f6c77b3"
+ ],
+ "ipatokenvendor": [
+ "FreeIPA"
+ ],
+ "objectclass": [
+ "top",
+ "ipatokentotp",
+ "ipatoken"
+ ]
+ },
+ "summary": null,
+ "value": "10bd43b5-3204-4695-9225-91064f6c77b3"
+ }
+ ]
+ }
+} \ No newline at end of file
diff --git a/install/ui/test/data/otptoken_mod.json b/install/ui/test/data/otptoken_mod.json
new file mode 100644
index 000000000..83cec6063
--- /dev/null
+++ b/install/ui/test/data/otptoken_mod.json
@@ -0,0 +1,72 @@
+{
+ "error": null,
+ "id": null,
+ "result": {
+ "messages": [
+ {
+ "code": 13001,
+ "message": "API Version number was not sent, forward compatibility not guaranteed. Assuming server's API version, 2.83",
+ "name": "VersionMissing",
+ "type": "warning"
+ }
+ ],
+ "result": {
+ "attributelevelrights": {
+ "aci": "rscwo",
+ "description": "rscwo",
+ "ipatokendisabled": "rscwo",
+ "ipatokenmodel": "rscwo",
+ "ipatokennotafter": "rscwo",
+ "ipatokennotbefore": "rscwo",
+ "ipatokenotpalgorithm": "rscwo",
+ "ipatokenotpdigits": "rscwo",
+ "ipatokenotpkey": "rscwo",
+ "ipatokenowner": "rscwo",
+ "ipatokenserial": "rscwo",
+ "ipatokentotpclockoffset": "rscwo",
+ "ipatokentotptimestep": "rscwo",
+ "ipatokenuniqueid": "rscwo",
+ "ipatokenvendor": "rscwo",
+ "nsaccountlock": "rscwo",
+ "objectclass": "rscwo"
+ },
+ "description": [
+ "a"
+ ],
+ "dn": "ipatokenuniqueid=10bd43b5-3204-4695-9225-91064f6c77b3,cn=otp,dc=example,dc=com",
+ "ipatokenmodel": [
+ "totp"
+ ],
+ "ipatokenotpalgorithm": [
+ "sha1"
+ ],
+ "ipatokenotpdigits": [
+ "6"
+ ],
+ "ipatokenotpkey": [
+ {
+ "__base64__": "zxQLlzbl+khKOw=="
+ }
+ ],
+ "ipatokentotpclockoffset": [
+ "0"
+ ],
+ "ipatokentotptimestep": [
+ "30"
+ ],
+ "ipatokenuniqueid": [
+ "10bd43b5-3204-4695-9225-91064f6c77b3"
+ ],
+ "ipatokenvendor": [
+ "FreeIPA"
+ ],
+ "objectclass": [
+ "top",
+ "ipatokentotp",
+ "ipatoken"
+ ]
+ },
+ "summary": "Modified OTP token \"10bd43b5-3204-4695-9225-91064f6c77b3\"",
+ "value": "10bd43b5-3204-4695-9225-91064f6c77b3"
+ }
+}
diff --git a/install/ui/test/data/otptoken_show.json b/install/ui/test/data/otptoken_show.json
new file mode 100644
index 000000000..96c149d9d
--- /dev/null
+++ b/install/ui/test/data/otptoken_show.json
@@ -0,0 +1,51 @@
+{
+ "error": null,
+ "id": null,
+ "result": {
+ "result": {
+ "description": [
+ "Description"
+ ],
+ "dn": "ipatokenuniqueid=10bd43b5-3204-4695-9225-91064f6c77b3,cn=otp,dc=example,dc=com",
+ "ipatokendisabled": [
+ "TRUE"
+ ],
+ "ipatokenmodel": [
+ "totp"
+ ],
+ "ipatokenotpalgorithm": [
+ "sha1"
+ ],
+ "ipatokenotpdigits": [
+ "6"
+ ],
+ "ipatokenotpkey": [
+ {
+ "__base64__": "++R6gVcVPHzz3Q=="
+ }
+ ],
+ "ipatokenowner": [
+ "admin"
+ ],
+ "ipatokentotpclockoffset": [
+ "0"
+ ],
+ "ipatokentotptimestep": [
+ "30"
+ ],
+ "ipatokenuniqueid": [
+ "10bd43b5-3204-4695-9225-91064f6c77b3"
+ ],
+ "ipatokenvendor": [
+ "FreeIPA"
+ ],
+ "objectclass": [
+ "top",
+ "ipatokentotp",
+ "ipatoken"
+ ]
+ },
+ "summary": null,
+ "value": "10bd43b5-3204-4695-9225-91064f6c77b3"
+ }
+} \ No newline at end of file