# Security

## **MetaMask Security Model**

The XRP Ledger Snap operates within MetaMask’s secure environment, ensuring that your data and assets are protected at all times. Snaps run in a sandboxed environment, meaning they are isolated from your MetaMask account data and other browser extensions. This isolation, combined with a strict permissions model, allows you to control what each Snap can access. Before installing the XRP Ledger Snap, you can review and verify the permissions it requests.&#x20;

{% hint style="info" %}
Your private keys never leave the Snap. All cryptographic operations are performed securely within the Snap, keeping your keys safe from exposure.
{% endhint %}

{% embed url="<https://metamask.io/snaps/>" %}

## **Code Audited by Safer**

To further ensure the security of the XRP Ledger Snap, its code has been audited by Safer, a leading blockchain security firm. Safer’s comprehensive audit covered the entire codebase, identifying and addressing potential vulnerabilities to ensure the Snap operates securely within MetaMask. The Snap is also subject to continuous monitoring and updates, ensuring that it remains secure against any emerging threats over time.

{% embed url="<https://sayfer.io/audits/metamask-snap-audit-report-for-peersyst/>" %}

## **Secure Network Interactions with xrpl.js**

In addition to these safeguards, the XRP Ledger Snap utilizes the well-audited xrpl.js library to interact with the XRP Ledger network. This library is trusted by the XRP Ledger developer community and is regularly updated to incorporate the latest security enhancements. By using xrpl.js, the XRP Ledger Snap ensures that all interactions with the XRP Ledger are conducted securely and reliably, providing you with peace of mind while managing your XRP and other tokens.

{% embed url="<https://github.com/XRPLF/xrpl.js>" %}


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://snap-docs.xrplevm.org/basics/security.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
