# Using Linux's memfd\_secret syscall from the JVM with JEP-419 JEP-454

DevFeed: [Using Linux's memfd\_secret syscall from the JVM with JEP-419 JEP-454](<https://devfeed.tech/articles/using-linux-s-memfd-secret-syscall-from-the-jvm-with-jep-419-jep-454-26084.md>)

Original publisher: [Read original article](<https://blog.arkey.fr/2022/05/16/linux_memfd_secret_with_jep-419/>)

Author: brice.dutheil@gmail.com (Brice Dutheil)

Published: 2022-05-15T22:32:09Z

Content type: tutorial

Language: en

Sources: [The Coffee Workshop](<https://devfeed.tech/sources/the-coffee-workshop.md>)

Topics: [Linux](<https://devfeed.tech/topics/linux.md>), [Java](<https://devfeed.tech/topics/java.md>), [Kernel](<https://devfeed.tech/topics/kernel.md>), [Operating system](<https://devfeed.tech/topics/operating-system.md>), [API](<https://devfeed.tech/topics/api.md>), [Security](<https://devfeed.tech/topics/security.md>), [cpu](<https://devfeed.tech/topics/cpu.md>)

Tags: [api](<https://devfeed.tech/tags/api.md>), [cpu](<https://devfeed.tech/tags/cpu.md>), [java](<https://devfeed.tech/tags/java.md>), [jdk](<https://devfeed.tech/tags/jdk.md>), [kernel](<https://devfeed.tech/tags/kernel.md>), [linux](<https://devfeed.tech/tags/linux.md>), [security](<https://devfeed.tech/tags/security.md>)

## AI overview

A tutorial explains how to use Linux's memfd_secret system call from the JVM through the Foreign Function & Memory API associated with JEP-454. It introduces the system call's role in protecting memory segments from kernel access and explains the system-call and processor-protection concepts needed to understand the example.

## Source excerpt

Linux 5.14 brought a new system call memfd_secret in order to mitigate speculative attack by preventing the kernel from being able to peek at these memory segments. Let's use this syscall from the JVM with the ~JEP-419~ JEP-454 API.