> For the complete documentation index, see [llms.txt](https://libsodium.gitbook.io/doc/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://libsodium.gitbook.io/doc/secret-key_cryptography.md).

# Secret-key cryptography

- [Authenticated encryption](https://libsodium.gitbook.io/doc/secret-key_cryptography/secretbox.md)
- [Encrypted streams and file encryption](https://libsodium.gitbook.io/doc/secret-key_cryptography/secretstream.md)
- [Encrypting a set of related messages](https://libsodium.gitbook.io/doc/secret-key_cryptography/encrypted-messages.md)
- [Authentication](https://libsodium.gitbook.io/doc/secret-key_cryptography/secret-key_authentication.md)
- [AEAD constructions](https://libsodium.gitbook.io/doc/secret-key_cryptography/aead.md)
- [ChaCha20-Poly1305](https://libsodium.gitbook.io/doc/secret-key_cryptography/aead/chacha20-poly1305.md)
- [Original ChaCha20-Poly1305 construction](https://libsodium.gitbook.io/doc/secret-key_cryptography/aead/chacha20-poly1305/original_chacha20-poly1305_construction.md)
- [IETF ChaCha20-Poly1305 construction](https://libsodium.gitbook.io/doc/secret-key_cryptography/aead/chacha20-poly1305/ietf_chacha20-poly1305_construction.md)
- [XChaCha20-Poly1305 construction](https://libsodium.gitbook.io/doc/secret-key_cryptography/aead/chacha20-poly1305/xchacha20-poly1305_construction.md)
- [AEGIS-256](https://libsodium.gitbook.io/doc/secret-key_cryptography/aead/aegis-256.md)
- [AEGIS-128L](https://libsodium.gitbook.io/doc/secret-key_cryptography/aead/aegis-128l.md)
- [AES256-GCM](https://libsodium.gitbook.io/doc/secret-key_cryptography/aead/aes-256-gcm.md)
- [AES256-GCM with precomputation](https://libsodium.gitbook.io/doc/secret-key_cryptography/aead/aes-256-gcm/aes-gcm_with_precomputation.md)
- [IP address encryption](https://libsodium.gitbook.io/doc/secret-key_cryptography/ip_address_encryption.md)


---

# 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 dynamically by asking a question.

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

```
GET https://libsodium.gitbook.io/doc/secret-key_cryptography.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.
