Archived | Create a secure server-side application where all data is encrypted in flight, at rest, and in use

Archived content

Archive date: 2020-01-17

This content is no longer being updated or maintained. The content is provided “as is.” Given the rapid evolution of technology, some content, steps, or illustrations may have changed.


This server-side application, written in Swift, will use the Hyper Protect DBaaS services. IBM Hyper Protect Services bring continuous security to IBM Cloud, so all data is encrypted in flight, at rest, and in use.


Two major themes bookend the conversation around cloud adoption. You are being asked to move quickly to take advantage of scale and technologies offered through Cloud like AI, machine learning, IoT, and even quantum, but security and privacy concerns are in your mind if you move too quickly. This code pattern will help you build a Swift backend that takes advantage of IBM Hyper Protect DBaaS, a service that allows you to retain your data in a fully-encrypted database without the need for specialized skills. This code pattern gives you the foundation you need to start creating an app that is immediately enabled for IBM Hyper Protect DBaaS. Or, you can copy and paste the code into an existing application.

This code pattern makes it very easy to follow a Cloud Native programming model that uses IBM’s best practices for app development. You’ll see things like test cases, health check, and metrics. Once a Hyper Protect DBaaS service with MongoDB is provisioned, click on Build on IBM Cloud at the top of the code pattern to generate an application.

This code pattern will teach you how to:

  • Provision and integrate Hyper Protect DBaaS
  • Generate an application with files for deploying to Kubernetes, Cloud Foundry or a DevOps Pipeline
  • Generate an application with files for monitoring and distributed trace using App Metrics
  • Connect to additional provisioned services


Secure server-side app with Kitura and Hyper Protect services architecture diagram

  1. The Swift mobile application communicates directly with the Hyper Protect Services.
  2. Optionally, the Swift mobile application can communicate directly with other IBM Cloud services, such as a Cloudant NoSQL database.
  3. Lastly, the Swift mobile application communicates directly with the Push Notification service.


See the detailed instructions in the README file.