[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libeufin] 02/02: remove deprecated endpoint
From: |
gnunet |
Subject: |
[libeufin] 02/02: remove deprecated endpoint |
Date: |
Wed, 13 Jan 2021 17:16:21 +0100 |
This is an automated email from the git hooks/post-receive script.
dold pushed a commit to branch master
in repository libeufin.
commit 49469cea6776ba0cd0142794d2517284df45b5a2
Author: Florian Dold <florian@dold.me>
AuthorDate: Wed Jan 13 17:16:16 2021 +0100
remove deprecated endpoint
---
integration-tests/start-testenv.py | 8 +++----
integration-tests/tests.py | 2 +-
.../src/main/kotlin/tech/libeufin/sandbox/Main.kt | 27 ----------------------
3 files changed, 5 insertions(+), 32 deletions(-)
diff --git a/integration-tests/start-testenv.py
b/integration-tests/start-testenv.py
index 634b93e..24833c1 100755
--- a/integration-tests/start-testenv.py
+++ b/integration-tests/start-testenv.py
@@ -99,25 +99,25 @@ startSandbox()
# 0.a Create EBICS hosts
assertResponse(
post(
- "http://localhost:5000/admin/ebics/host",
+ "http://localhost:5000/admin/ebics/hosts",
json=dict(hostID=BC1_HOST_ID, ebicsVersion=EBICS_VERSION),
)
)
assertResponse(
post(
- "http://localhost:5000/admin/ebics/host",
+ "http://localhost:5000/admin/ebics/hosts",
json=dict(hostID=BC2_HOST_ID, ebicsVersion=EBICS_VERSION),
)
)
assertResponse(
post(
- "http://localhost:5000/admin/ebics/host",
+ "http://localhost:5000/admin/ebics/hosts",
json=dict(hostID=BC3_HOST_ID, ebicsVersion=EBICS_VERSION),
)
)
assertResponse(
post(
- "http://localhost:5000/admin/ebics/host",
+ "http://localhost:5000/admin/ebics/hosts",
json=dict(hostID=BC4_HOST_ID, ebicsVersion=EBICS_VERSION),
)
)
diff --git a/integration-tests/tests.py b/integration-tests/tests.py
index 0d3bf0e..4faf676 100755
--- a/integration-tests/tests.py
+++ b/integration-tests/tests.py
@@ -35,7 +35,7 @@ def prepareSandbox():
# make ebics host at sandbox
assertResponse(
post(
- f"{PERSONA.banking.bank_base_url}/admin/ebics/host",
+ f"{PERSONA.banking.bank_base_url}/admin/ebics/hosts",
json=dict(hostID=PERSONA.ebics.host,
ebicsVersion=PERSONA.ebics.version),
)
)
diff --git a/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
b/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
index b030eeb..7152169 100644
--- a/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
+++ b/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
@@ -387,33 +387,6 @@ fun serverMain(dbName: String, port: Int) {
call.respond(ret)
return@get
}
- /**
- * Creates a new EBICS host.
- *
- * FIXME: This endpoint is deprecated. /hosts should be used
instead.
- */
- post("/admin/ebics/host") {
- val req = call.receive<EbicsHostCreateRequest>()
- val pairA = CryptoUtil.generateRsaKeyPair(2048)
- val pairB = CryptoUtil.generateRsaKeyPair(2048)
- val pairC = CryptoUtil.generateRsaKeyPair(2048)
- transaction {
- EbicsHostEntity.new {
- this.ebicsVersion = req.ebicsVersion
- this.hostId = req.hostID
- this.authenticationPrivateKey =
ExposedBlob(pairA.private.encoded)
- this.encryptionPrivateKey =
ExposedBlob(pairB.private.encoded)
- this.signaturePrivateKey =
ExposedBlob(pairC.private.encoded)
- }
- }
- call.respondText(
- "Host '${req.hostID}' created.",
- ContentType.Text.Plain,
- HttpStatusCode.OK
- )
- return@post
- }
-
/**
* Creates a new EBICS host.
*/
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.