Rate This Document
Findability
Accuracy
Completeness
Readability

KCAL Middleware

Figure 1 KCAL middleware deployment and usage
  • Third-party upper-layer PPC applications can utilize the KCAL capabilities by calling the middleware, adding data adaptation layers, and calling the corresponding client APIs.
  • KCAL uses Kunpeng confidential VMs and in-house protocols for dual encryption, and provides dedicated high- and low-order operators to enhance data security in various computing scenarios in a way that data is available but invisible.
  • The operator acceleration service maximizes the performance based on the hardware instruction capabilities of Kunpeng chips.

KCAL APIs

  • KCAL_Config
    struct KCAL_Config {
    int nodeId;
    int fixBits;
    int threadCount;
    int worldSize;
    bool useSMAlg;
    };

    This structure is used as a configuration item to build the KCAL middleware context, including the custom node ID, fixed-point number bits, number of threads, number of participants, and SM algorithm enablement configuration.

  • Context::Create
    std::shared_ptr<Context> Context::Create(KCAL_Config config, TEE_NET_RES *netRes, KCAL_AlgorithmsType type);

    You can create a context for calling KCAL by passing the configuration, network callback API, and algorithm type.

  • Future API support

    Currently, only the PSI/PIR APIs of KCAL are supported. Binary operations and multi-party operator APIs will be supported.

  • For details about how to integrate KCAL middleware with a third-party library, see KCAL Middleware Integration with Ant Group's PSI Library.