Getting Started
MineZues(TM) AM provides Attestation & Monitoring services for MPoC solution. MineZeus is designed to manage the whole licfe-cycle of MPoC SDK. It implements phone/device (COTS) trust identity management(root-of-trust), regular security monitoring and COTS baseline management. MineZues AM service must be used together with MineHades MPoC SDK.A general diagram of MineZeus AM function is shown below. The MineZeus provides two group of interfaces. One set of interfaces are for MPoC SDK , which is used to interact with SDK. The other set is provided to payment host side, which provides APIs to for payment system to read the status and data of each SDK.
API Request Model
MineZeus AM uses the following interaction mode with payment host. Https (with TLSv1.2) is used as secure protocl between AM server and payment host. A general sequence diagram
of API invocation is described below.
MineZeus accepts GET/POST JSON http request. An example is provided as below.
fun httpPost(url: String, data: String, token: String? = null): String? {
val urlBuilder: HttpUrl.Builder =
Objects.requireNonNull(
java.lang.String.format("https://%s%s", "am.mspayhub.com/mpoc", url).toHttpUrlOrNull()
)!!.newBuilder()
token?.let {
urlBuilder.addQueryParameter("token", it)
}
val mtype = "application/json; charset=utf-8".toMediaType()
val postdata = data.trimIndent().toRequestBody(mtype)
//val httpUrl = String.format("https://%s%s", "am.mspayhub.com/mpoc", url)
val requestBuilder = Request.Builder().url(urlBuilder.build()).post(postdata)
val req = requestBuilder.build()
val call = client.newCall(req)
val response = call.execute()
val resp = response.body?.string()
response.close()
return resp
}
MineZeus returns data object using a uniform format. An exmaple of API response is give below.
{
"msg": "success",
"code": 0,
"data": {
"sdkId": "82f8a1ae2e231a38",
"deviceId": "",
"version": "1.10.106",
"state": "VALID",
"attestResult": "HEALTH",
"attestResultAdvice": "success",
"attestTime": 1691558572000
}
}
- msg - the server message indicating error details. it will be "success" when invocation is success. Otherwise it describes the detail of error.
- code - API response code. code = 0 means success and others indicate a failure.
- data - data object which varies in terms of API definition. It maybe null if
code != 0