> For the complete documentation index, see [llms.txt](https://docs.openg2p.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.openg2p.org/products/registry/registry/_archive/social-registry/features/privacy-and-security.md).

# Privacy and Security

Social Registry typically contains rich demographic information of persons. Hence, privacy and security of this data if utmost importance. OpenG2P offers several features related to privacy and security

* Encryption of PII at rest
* Anonymized eligibility and entitlement determination
* Anonymous data for reporting
* Role based access to data
* Multi factor authentication
* Robust secure deployment infrastructure
* HSM based Key Manager for encryption and digital signatures
* [Secure input handling](https://openg2p.gitbook.io/1.2-reorg/Kh7IXykse3jg1KAO6g2b/social-registry/privacy-and-security#secure-input-handling)

## Secure input handling <a href="#secure-input-handling" id="secure-input-handling"></a>

Input security is handled in the following ways:

* Input validation
* Memory safe programming language (Python)
* Type safe programming using Python Pydantic
* ORM capabilities to avoid SQL Injection threats

## Encryption of PII

* Social Registry fields can be encrypted and stored. Or the registry data can be anonymized.
* Social Registry uses [MOSIP Keymanager](https://docs.mosip.io/1.2.0/modules/keymanager) module for cryptography APIs. Keymanager uses HSM to store keys and perform operations like encrypting, signing, etc. so that the real keys are stored in HSM.
* Know more about [Privacy and Security in OpenG2P](/platform/platform-services/privacy-and-security.md). And about [Keymanager integration](/platform/platform-services/privacy-and-security/key-manager.md).
* Link to [Configuration and source code](/products/pbms/_archive/previous-generation/developer-zone/repositories/openg2p-security.md).

<figure><img src="https://3034178245-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJZcdob2emEcLMvLyIxqT%2Fuploads%2FYRlXkzihNG1uneypodK4%2FRegistry%20Keymanager.jpg?alt=media&amp;token=1436088f-79be-49e2-9811-154971e38f7e" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.openg2p.org/products/registry/registry/_archive/social-registry/features/privacy-and-security.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
