# French translation of manpages # This file is distributed under the same license as the manpages-l10n package. # Copyright © of this file: # Christophe Blaess , 1996-2003. # Stéphan Rafin , 2002. # Thierry Vignaud , 1999,2002. # François Micaux, 2002. # Alain Portal , 2003-2008. # Jean-Philippe Guérard , 2005-2006. # Jean-Luc Coulon (f5ibh) , 2006-2007. # Julien Cristau , 2006-2007. # Thomas Huriaux , 2006-2008. # Nicolas François , 2006-2008. # Florentin Duneau , 2006-2010. # Simon Paillard , 2006, 2012-2014. # Denis Barbier , 2006,2010. # David Prévot , 2010-2014. # Jean-Philippe MENGUAL , 2020-2024. msgid "" msgstr "" "Project-Id-Version: manpages-l10n 4.21.0\n" "POT-Creation-Date: 2024-06-01 06:02+0200\n" "PO-Revision-Date: 2024-03-13 11:04+0100\n" "Last-Translator: Jean-Philippe MENGUAL \n" "Language-Team: French \n" "Language: fr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n > 1;\n" "X-Generator: vim\n" #. type: TH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "memfd_create" msgstr "memfd_create" #. type: TH #: archlinux debian-unstable opensuse-tumbleweed #, no-wrap msgid "2024-05-02" msgstr "2 mai 2024" #. type: TH #: archlinux debian-unstable #, no-wrap msgid "Linux man-pages 6.8" msgstr "Pages du manuel de Linux 6.8" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "NAME" msgstr "NOM" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "memfd_create - create an anonymous file" msgstr "memfd_create - Créer un fichier anonyme" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "LIBRARY" msgstr "BIBLIOTHÈQUE" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Standard C library (I, I<-lc>)" msgstr "Bibliothèque C standard (I, I<-lc>)" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "SYNOPSIS" msgstr "SYNOPSIS" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "B<#define _GNU_SOURCE> /* See feature_test_macros(7) */\n" "B<#include Esys/mman.hE>\n" msgstr "" "B<#define _GNU_SOURCE> /* Consultez feature_test_macros(7) */\n" "B<#include Esys/mman.hE>\n" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "BIB<, unsigned int >IB<);>\n" msgstr "BIB<, unsigned int >IB<);>\n" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "DESCRIPTION" msgstr "DESCRIPTION" #. David Herrmann: #. memfd uses VM_NORESERVE so each page is accounted on first access. #. This means, the overcommit-limits (see __vm_enough_memory()) and the #. memory-cgroup limits (mem_cgroup_try_charge()) are applied. Note that #. those are accounted on "current" and "current->mm", that is, the #. process doing the first page access. #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "B() creates an anonymous file and returns a file descriptor " "that refers to it. The file behaves like a regular file, and so can be " "modified, truncated, memory-mapped, and so on. However, unlike a regular " "file, it lives in RAM and has a volatile backing storage. Once all " "references to the file are dropped, it is automatically released. Anonymous " "memory is used for all backing pages of the file. Therefore, files created " "by B() have the same semantics as other anonymous memory " "allocations such as those allocated using B(2) with the " "B flag." msgstr "" "B() crée un fichier anonyme et renvoie un descripteur de " "fichier qui s'y rapporte. Le fichier se comporte comme un fichier normal, il " "peut donc être modifié, tronqué, projeté en mémoire, et ainsi de suite. Mais " "contrairement à un fichier normal, il réside dans la RAM et son stockage est " "volatile. Une fois que toutes les références au fichier ont disparu, il est " "automatiquement libéré. La mémoire anonyme est utilisée pour toutes les " "pages de sauvegarde du fichier. Les fichiers créés par B() ont " "donc la même sémantique que les autres allocations de mémoire anonyme telles " "que celles qui utilisent B(2) avec l'attribut B." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The initial size of the file is set to 0. Following the call, the file size " "should be set using B(2). (Alternatively, the file may be " "populated by calls to B(2) or similar.)" msgstr "" "La taille initiale du fichier est positionnée à B<0>. Après l'appel, elle " "devrait être définie en utilisant B(2) (ou le fichier peut être " "rempli par des appels à B(2) ou équivalent)." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The name supplied in I is used as a filename and will be displayed as " "the target of the corresponding symbolic link in the directory I. The displayed name is always prefixed with I and serves only " "for debugging purposes. Names do not affect the behavior of the file " "descriptor, and as such multiple files can have the same name without any " "side effects." msgstr "" "Le nom fourni dans I est utilisé comme nom de fichier et sera affiché " "en tant que cible du lien symbolique correspondant dans le répertoire I. Le nom affiché a toujours un préfixe I et il ne sert " "que pour le débogage. Les noms ne changent pas le comportement du " "descripteur de fichier et en tant que tels plusieurs fichiers peuvent avoir " "le même nom sans effets de bord." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The following values may be bitwise ORed in I to change the behavior " "of B():" msgstr "" "Les valeurs suivantes peuvent subir une opération OU logique bit à bit dans " "I pour modifier le comportement de B() :" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Set the close-on-exec (B) flag on the new file descriptor. See " "the description of the B flag in B(2) for reasons why this " "may be useful." msgstr "" "Placer l'attribut « close-on-exec » (B) sur le nouveau " "descripteur de fichier. Consultez la description de l'attribut B " "dans B(2) pour savoir pourquoi cela peut être utile." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. FIXME Why is the MFD_ALLOW_SEALING behavior not simply the default? #. Is it worth adding some text explaining this? #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Allow sealing operations on this file. See the discussion of the " "B and B operations in B(2), and also NOTES, " "below. The initial set of seals is empty. If this flag is not set, the " "initial set of seals will be B, meaning that no other seals can " "be set on the file." msgstr "" "Permettre des opérations de verrouillage sur ce fichier. Voir le point sur " "les opérations B et B dans B(2), ainsi que " "les NOTES ci-dessous. Le positionnement initial des verrous est vide. Si cet " "attribut n'est pas défini, le positionnement initial des verrous sera " "B, ce qui veut dire qu'aucun autre verrou ne peut être " "positionné sur le fichier." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B (since Linux 4.14)" msgstr "B (depuis Linux 4.14)" #. commit 749df87bd7bee5a79cef073f5d032ddb2b211de8 #. commit 47b9012ecdc747f6936395265e677d41e11a31ff #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The anonymous file will be created in the hugetlbfs filesystem using huge " "pages. See the Linux kernel source file I for more information about hugetlbfs. Specifying both " "B and B in I is supported since Linux " "4.16." msgstr "" "Le fichier anonyme sera créé sur le système de fichiers hugetlbfs en " "utilisant d'immenses pages. Voir le fichier I des sources du noyau Linux pour plus d'informations sur " "hugetlbfs. Le fait d'indiquer à la fois B et " "B dans I est pris en charge depuis Linux 4.16." #. type: TP #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: TQ #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: TQ #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed #, no-wrap msgid "\\&.\\|.\\|." msgstr "\\&.\\|.\\|." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Used in conjunction with B to select alternative hugetlb page " "sizes (respectively, 2\\ MB, 1\\ GB, ...) on systems that support multiple " "hugetlb page sizes. Definitions for known huge page sizes are included in " "the header file Ilinux/memfd.hE.>" msgstr "" "Utilisé avec B pour sélectionner d'autres tailles de page " "hugetlb (respectivement 2 Mo, 1 Go, ...) sur les systèmes qui gèrent " "plusieurs tailles de page hugetlb. Les définitions des tailles de page " "immenses connues figurent dans le fichier d'entête Ilinux/memfd." "hE>." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "For details on encoding huge page sizes not included in the header file, see " "the discussion of the similarly named constants in B(2)." msgstr "" "Pour des détails sur l'encodage des tailles des pages immenses ne figurant " "pas dans le fichier d'entête, voir le point sur les constantes du même nom " "dans B(2)." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Unused bits in I must be 0." msgstr "Les bits inusitées dans I doivent valoir B<0>." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "As its return value, B() returns a new file descriptor that " "can be used to refer to the file. This file descriptor is opened for both " "reading and writing (B) and B is set for the file " "descriptor." msgstr "" "En code de retour, B() renvoie un nouveau descripteur de " "fichier qui peut être utilisé pour se référer au fichier. Ce descripteur de " "fichier est ouvert en lecture et en écriture (B) et B " "est positionné pour le descripteur de fichier." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "With respect to B(2) and B(2), the usual semantics apply for " "the file descriptor created by B(). A copy of the file " "descriptor is inherited by the child produced by B(2) and refers to " "the same file. The file descriptor is preserved across B(2), unless " "the close-on-exec flag has been set." msgstr "" "Par rapport à B(2) et B(2), la sémantique habituelle " "s'applique au descripteur de fichier créé par B(). Une copie " "du descripteur de fichier est récupérée par l'enfant produit par B(2) " "et elle se rapporte au même fichier. Le descripteur de fichier est préservé " "pendant un B(2), sauf si l'attribut close-on-exec a été positionné." #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "RETURN VALUE" msgstr "VALEUR RENVOYÉE" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "On success, B() returns a new file descriptor. On error, -1 " "is returned and I is set to indicate the error." msgstr "" "En cas de succès, B() renvoie un nouveau descripteur de " "fichier. En cas d'erreur, B<-1> est renvoyé et I est positionné pour " "indiquer l'erreur." #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "ERRORS" msgstr "ERREURS" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The address in I points to invalid memory." msgstr "L'adresse dans I pointe vers une mémoire non valable." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "I included unknown bits." msgstr "I comprend des bits inconnus." #. NAME_MAX - strlen("memfd:") #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "I was too long. (The limit is 249 bytes, excluding the terminating " "null byte.)" msgstr "" "I était trop long (la limite de 249 octets, n'incluant pas l'octet " "NULL final)." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Both B and B were specified in I." msgstr "" "B et B ont tous deux été indiqués dans " "I." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The per-process limit on the number of open file descriptors has been " "reached." msgstr "" "La limite du nombre de descripteurs de fichiers par processus a été atteinte." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The system-wide limit on the total number of open files has been reached." msgstr "" "La limite du nombre total de fichiers ouverts pour le système entier a été " "atteinte." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "There was insufficient memory to create a new anonymous file." msgstr "Mémoire insuffisante pour créer un nouveau fichier anonyme." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B flag was specified, but the caller was not privileged " "(did not have the B capability) and is not a member of the " "I group; see the description of I in B(5)." msgstr "" "L'attribut B a été spécifié, mais l'appelant n'est pas un " "utilisateur privilégié (il n'a pas la capacité B) et il n'est " "pas membre du groupe I ; consultez la description " "de I dans B(5)." #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "STANDARDS" msgstr "STANDARDS" #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-leap-15-6 opensuse-tumbleweed msgid "Linux." msgstr "Linux." #. type: SH #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "HISTORY" msgstr "HISTORIQUE" #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-leap-15-6 opensuse-tumbleweed msgid "Linux 3.17, glibc 2.27." msgstr "Linux 3.17, glibc 2.27." #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "NOTES" msgstr "NOTES" #. See also http://lwn.net/Articles/593918/ #. and http://lwn.net/Articles/594919/ and http://lwn.net/Articles/591108/ #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B() system call provides a simple alternative to manually " "mounting a B(5) filesystem and creating and opening a file in that " "filesystem. The primary purpose of B() is to create files " "and associated file descriptors that are used with the file-sealing APIs " "provided by B(2)." msgstr "" "L'appel système B() offre une alternative simple au montage " "manuel d'un système de fichiers B(5) et à la création et l'ouverture " "d'un fichier dans ce système de fichiers. Le premier objectif de " "B() est de créer des fichiers et leur descripteur associé, " "utilisés avec les API de verrou de fichiers fournis par B(2)." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B() system call also has uses without file sealing (which " "is why file-sealing is disabled, unless explicitly requested with the " "B flag). In particular, it can be used as an alternative " "to creating files in I or as an alternative to using the B(2) " "B in cases where there is no intention to actually link the " "resulting file into the filesystem." msgstr "" "L'appel système B() s'utilise également sans verrou de fichier " "(c'est pourquoi le verrouillage de fichier a été désactivé sauf demande " "explicite avec l'attribut B). En particulier, il peut " "être utilisé comme alternative pour créer des fichiers dans I ou pour " "utiliser B de B(2), si vous ne voulez pas rattacher le " "fichier résultant au système de fichiers." #. type: SS #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "File sealing" msgstr "Verrou de fichiers" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "In the absence of file sealing, processes that communicate via shared memory " "must either trust each other, or take measures to deal with the possibility " "that an untrusted peer may manipulate the shared memory region in " "problematic ways. For example, an untrusted peer might modify the contents " "of the shared memory at any time, or shrink the shared memory region. The " "former possibility leaves the local process vulnerable to time-of-check-to-" "time-of-use race conditions (typically dealt with by copying data from the " "shared memory region before checking and using it). The latter possibility " "leaves the local process vulnerable to B signals when an attempt is " "made to access a now-nonexistent location in the shared memory region. " "(Dealing with this possibility necessitates the use of a handler for the " "B signal.)" msgstr "" "En l'absence de verrou de fichier, les processus qui communiquent à travers " "la mémoire partagée doivent soit se faire confiance entre eux, soit prendre " "des mesures pour gérer la possibilité qu'un pair non fiable manipule la " "région de mémoire partagée de manière problématique. Par exemple, un pair " "non fiable pourrait modifier le contenu de la mémoire partagée n'importe " "quand ou rétrécir la zone de mémoire partagée. La première éventualité rend " "le processus local vulnérable aux conflits (race conditions) time-of-check-" "to-time-of-use (généralement gérés en copiant les données de la zone de " "mémoire partagée avant de les vérifier et de les utiliser). La deuxième " "éventualité rend le processus local vulnérable aux signaux B quand " "on essaie d'accéder à un emplacement inexistant dans la zone de mémoire " "partagée (gérer cette éventualité implique d'utiliser un gestionnaire pour " "le signal B)." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Dealing with untrusted peers imposes extra complexity on code that employs " "shared memory. Memory sealing enables that extra complexity to be " "eliminated, by allowing a process to operate secure in the knowledge that " "its peer can't modify the shared memory in an undesired fashion." msgstr "" "La gestion de pairs non fiables impose une plus grande complexité du code " "qui utilise la mémoire partagée. Les verrous mémoire éliminent cette " "complexité, en permettant à un processus d'agir en toute sécurité en sachant " "que son pair ne peut pas modifier la mémoire partagée de manière non " "souhaitée." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "An example of the usage of the sealing mechanism is as follows:" msgstr "Voici un exemple d'utilisation du mécanisme de verrouillage :" #. type: IP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "(1)" msgstr "(1)" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The first process creates a B(5) file using B(). The " "call yields a file descriptor used in subsequent steps." msgstr "" "Le premier processus crée un fichier B(5) en utilisant " "B(). L'appel donne un descripteur de fichier utilisé dans les " "étapes ultérieures." #. type: IP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "(2)" msgstr "(2)" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The first process sizes the file created in the previous step using " "B(2), maps it using B(2), and populates the shared memory " "with the desired data." msgstr "" "Le premier processus dimensionne le fichier créé à l'étape précédente en " "utilisant B(2), il le projette en utilisant B(2) et il " "remplit la mémoire partagée avec les données désirées." #. type: IP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "(3)" msgstr "(3)" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The first process uses the B(2) B operation to place " "one or more seals on the file, in order to restrict further modifications on " "the file. (If placing the seal B, then it will be necessary " "to first unmap the shared writable mapping created in the previous step. " "Otherwise, behavior similar to B can be achieved by using " "B, which will prevent future writes via B(2) and " "B(2) from succeeding while keeping existing shared writable " "mappings)." msgstr "" "Le premier processus utilise l'opération B de B(2) pour " "poser un ou plusieurs verrous sur le fichier afin de restreindre des " "modifications ultérieures (si on pose un verrou B, il sera " "nécessaire de désassocier la projection modifiable partagée créée à l'étape " "précédente. Sinon, on peut obtenir un comportement identique à " "B en utilisant B, qui empêchera des " "écritures ultérieures à l'aide de B(2) et de B(2), tout en " "conservant les projections modifiables partagées existantes)." #. type: IP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "(4)" msgstr "(4)" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "A second process obtains a file descriptor for the B(5) file and " "maps it. Among the possible ways in which this could happen are the " "following:" msgstr "" "Un deuxième processus obtient un descripteur de fichier pour le fichier " "B(5) et le projette. Parmi les origines possibles de cela, vous " "trouverez :" #. type: IP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "\\[bu]" msgstr "-" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The process that called B() could transfer the resulting file " "descriptor to the second process via a UNIX domain socket (see B(7) " "and B(3)). The second process then maps the file using B(2)." msgstr "" "Le processus qui a appelé B() a pu transférer le descripteur " "de fichier consécutif au deuxième processus à l'aide d'un socket de domaine " "UNIX (voir B(7) et B(3)). Le deuxième processus projette alors " "le fichier en utilisant B(2)." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The second process is created via B(2) and thus automatically " "inherits the file descriptor and mapping. (Note that in this case and the " "next, there is a natural trust relationship between the two processes, since " "they are running under the same user ID. Therefore, file sealing would not " "normally be necessary.)" msgstr "" "Le deuxième processus est créé à l'aide de B(2) et, ainsi, il récupère " "automatiquement le descripteur de fichier et sa projection (remarquez que " "dans ce cas et dans le prochain, il existe une relation de confiance " "naturelle entre les deux processus puisqu'ils tournent sous le même " "identifiant utilisateur. Donc, un verrou de fichier n'est, en principe, pas " "nécessaire)." #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The second process opens the file IpidIfd, where " "IpidE> is the PID of the first process (the one that called " "B()), and IfdE> is the number of the file descriptor " "returned by the call to B() in that process. The second " "process then maps the file using B(2)." msgstr "" "Le deuxième processus ouvre le fichier IpidIfd où " "IpidE> est l'identifiant de processus du premier processus (celui " "qui a appelé B()) et IfdE> est le numéro du " "descripteur de fichier renvoyé par l'appel à B dans ce " "processus. Le deuxième processus projette ensuite le fichier en utilisant " "B(2)." #. type: IP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "(5)" msgstr "(5)" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The second process uses the B(2) B operation to " "retrieve the bit mask of seals that has been applied to the file. This bit " "mask can be inspected in order to determine what kinds of restrictions have " "been placed on file modifications. If desired, the second process can apply " "further seals to impose additional restrictions (so long as the " "B seal has not yet been applied)." msgstr "" "Le deuxième processus utilise l'opération B de B(2) pour " "récupérer le masque de bits de verrous appliqué au fichier. Ce masque peut " "être examiné pour déterminer le type de restrictions posées aux " "modifications du fichier. Si vous le souhaitez, le deuxième processus peut " "appliquer des verrous supplémentaires pour imposer d'autres restrictions " "(tant que le verrou B n'a pas encore été appliqué)." #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "EXAMPLES" msgstr "EXEMPLES" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Below are shown two example programs that demonstrate the use of " "B() and the file sealing API." msgstr "" "Voici deux exemples de programme montrant l'utilisation de B() " "et de l'API de verrou de fichier." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The first program, I, creates a B(5) file using " "B(), sets a size for the file, maps it into memory, and " "optionally places some seals on the file. The program accepts up to three " "command-line arguments, of which the first two are required. The first " "argument is the name to associate with the file, the second argument is the " "size to be set for the file, and the optional third argument is a string of " "characters that specify seals to be set on the file." msgstr "" "Le premier programme, I, crée un fichier B(5) en " "utilisant B(), donne une taille au fichier, le projette en " "mémoire et, en option, pose des verrous sur le fichier. Le programme accepte " "jusqu'à trois paramètres en ligne de commande, dont les deux premiers sont " "requis. Le premier paramètre est le nom à donner au fichier, le deuxième est " "la taille à lui donner, le troisième, optionnel, est une chaîne de " "caractères qui indique les verrous à poser sur le fichier." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The second program, I, can be used to open an existing file " "that was created via B() and inspect the set of seals that " "have been applied to that file." msgstr "" "Le deuxième programme, I, peut être utilisé pour ouvrir un " "fichier existant créé à l'aide de B() et examiner les verrous " "qui y sont posés." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The following shell session demonstrates the use of these programs. First " "we create a B(5) file and set some seals on it:" msgstr "" "La session d'interpréteur suivant montre l'utilisation de ces programmes. " "Nous créons d'abord un fichier B(5) et nous posons des verrous " "dessus :" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "$ B<./t_memfd_create my_memfd_file 4096 sw &>\n" "[1] 11775\n" "PID: 11775; fd: 3; /proc/11775/fd/3\n" msgstr "" "$ B<./t_memfd_create my_memfd_file 4096 sw &>\n" "[1] 11775\n" "PID: 11775; fd: 3; /proc/11775/fd/3\n" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "At this point, the I program continues to run in the " "background. From another program, we can obtain a file descriptor for the " "file created by B() by opening the IpidI file " "that corresponds to the file descriptor opened by B(). Using " "that pathname, we inspect the content of the IpidI symbolic " "link, and use our I program to view the seals that have been " "placed on the file:" msgstr "" "À ce moment, le programme I continue à s'exécuter en tâche " "de fond. À partir d'un autre programme, nous pouvons obtenir un descripteur " "de fichier pour le fichier créé par B() en ouvrant IpidI qui correspond au descripteur de fichier ouvert par " "B(). En utilisant ce chemin, nous examinons le contenu du lien " "symbolique IpidI et nous utilisons notre programme " "I pour voir les verrous posés sur le fichier :" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "$ B\n" "/memfd:my_memfd_file (deleted)\n" "$ B<./t_get_seals /proc/11775/fd/3>\n" "Existing seals: WRITE SHRINK\n" msgstr "" "$ B\n" "/memfd:my_memfd_file (deleted)\n" "$ B<./t_get_seals /proc/11775/fd/3>\n" "Verrous existants : WRITE SHRINK\n" #. type: SS #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Program source: t_memfd_create.c" msgstr "Source du programme : t_memfd_create.c" #. type: Plain text #: archlinux debian-unstable opensuse-tumbleweed #, no-wrap msgid "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Efcntl.hE\n" "#include Estdint.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" "#include Esys/mman.hE\n" "#include Esys/types.hE\n" "#include Eunistd.hE\n" "\\&\n" "int\n" "main(int argc, char *argv[])\n" "{\n" " int fd;\n" " char *name, *seals_arg;\n" " ssize_t len;\n" " unsigned int seals;\n" "\\&\n" " if (argc E 3) {\n" " fprintf(stderr, \"%s name size [seals]\\en\", argv[0]);\n" " fprintf(stderr, \"\\et\\[aq]seals\\[aq] can contain any of the \"\n" " \"following characters:\\en\");\n" " fprintf(stderr, \"\\et\\etg - F_SEAL_GROW\\en\");\n" " fprintf(stderr, \"\\et\\ets - F_SEAL_SHRINK\\en\");\n" " fprintf(stderr, \"\\et\\etw - F_SEAL_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etW - F_SEAL_FUTURE_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etS - F_SEAL_SEAL\\en\");\n" " exit(EXIT_FAILURE);\n" " }\n" "\\&\n" " name = argv[1];\n" " len = atoi(argv[2]);\n" " seals_arg = argv[3];\n" "\\&\n" " /* Create an anonymous file in tmpfs; allow seals to be\n" " placed on the file. */\n" "\\&\n" " fd = memfd_create(name, MFD_ALLOW_SEALING);\n" " if (fd == -1)\n" " err(EXIT_FAILURE, \"memfd_create\");\n" "\\&\n" " /* Size the file as specified on the command line. */\n" "\\&\n" " if (ftruncate(fd, len) == -1)\n" " err(EXIT_FAILURE, \"truncate\");\n" "\\&\n" " printf(\"PID: %jd; fd: %d; /proc/%jd/fd/%d\\en\",\n" " (intmax_t) getpid(), fd, (intmax_t) getpid(), fd);\n" "\\&\n" " /* Code to map the file and populate the mapping with data\n" " omitted. */\n" "\\&\n" " /* If a \\[aq]seals\\[aq] command-line argument was supplied, set some\n" " seals on the file. */\n" "\\&\n" " if (seals_arg != NULL) {\n" " seals = 0;\n" "\\&\n" " if (strchr(seals_arg, \\[aq]g\\[aq]) != NULL)\n" " seals |= F_SEAL_GROW;\n" " if (strchr(seals_arg, \\[aq]s\\[aq]) != NULL)\n" " seals |= F_SEAL_SHRINK;\n" " if (strchr(seals_arg, \\[aq]w\\[aq]) != NULL)\n" " seals |= F_SEAL_WRITE;\n" " if (strchr(seals_arg, \\[aq]W\\[aq]) != NULL)\n" " seals |= F_SEAL_FUTURE_WRITE;\n" " if (strchr(seals_arg, \\[aq]S\\[aq]) != NULL)\n" " seals |= F_SEAL_SEAL;\n" "\\&\n" " if (fcntl(fd, F_ADD_SEALS, seals) == -1)\n" " err(EXIT_FAILURE, \"fcntl\");\n" " }\n" "\\&\n" " /* Keep running, so that the file created by memfd_create()\n" " continues to exist. */\n" "\\&\n" " pause();\n" "\\&\n" " exit(EXIT_SUCCESS);\n" "}\n" msgstr "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Efcntl.hE\n" "#include Estdint.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" "#include Esys/mman.hE\n" "#include Esys/types.hE\n" "#include Eunistd.hE\n" "\\&\n" "int\n" "main(int argc, char *argv[])\n" "{\n" " int fd;\n" " char *name, *seals_arg;\n" " ssize_t len;\n" " unsigned int seals;\n" "\\&\n" " if (argc E 3) {\n" " fprintf(stderr, \"%s name size [seals]\\en\", argv[0]);\n" " fprintf(stderr, \"\\et\\[aq]seals\\[aq] peut contenir un des \"\n" " \"caractères suivants :\\en\");\n" " fprintf(stderr, \"\\et\\etg - F_SEAL_GROW\\en\");\n" " fprintf(stderr, \"\\et\\ets - F_SEAL_SHRINK\\en\");\n" " fprintf(stderr, \"\\et\\etw - F_SEAL_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etW - F_SEAL_FUTURE_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etS - F_SEAL_SEAL\\en\");\n" " exit(EXIT_FAILURE);\n" " }\n" "\\&\n" " name = argv[1];\n" " len = atoi(argv[2]);\n" " seals_arg = argv[3];\n" "\\&\n" " /* Créer un fichier anonyme dans tmpfs ; permet de poser\n" " des verrous sur le fichier. */\n" "\\&\n" " fd = memfd_create(name, MFD_ALLOW_SEALING);\n" " if (fd == -1)\n" " err(EXIT_FAILURE, \"memfd_create\");\n" "\\&\n" " /* Taille du fichier indiquée sur la ligne de commande. */\n" "\\&\n" " if (ftruncate(fd, len) == -1)\n" " err(EXIT_FAILURE, \"truncate\");\n" "\\&\n" " printf(\"PID: %jd; fd: %d; /proc/%jd/fd/%d\\en\",\n" " (intmax_t) getpid(), fd, (intmax_t) getpid(), fd);\n" "\\&\n" " /* Code pour projeter le fichier et remplir la projection\n" " avec des données omises. */\n" "\\&\n" " /* Si un paramètre \\[aq]seals\\[aq] de la ligne de commande est fourni,\n" " poser des verrous sur le fichier. */\n" "\\&\n" " if (seals_arg != NULL) {\n" " seals = 0;\n" "\\&\n" " if (strchr(seals_arg, \\[aq]g\\[aq]) != NULL)\n" " seals |= F_SEAL_GROW;\n" " if (strchr(seals_arg, \\[aq]s\\[aq]) != NULL)\n" " seals |= F_SEAL_SHRINK;\n" " if (strchr(seals_arg, \\[aq]w\\[aq]) != NULL)\n" " seals |= F_SEAL_WRITE;\n" " if (strchr(seals_arg, \\[aq]W\\[aq]) != NULL)\n" " seals |= F_SEAL_FUTURE_WRITE;\n" " if (strchr(seals_arg, \\[aq]S\\[aq]) != NULL)\n" " seals |= F_SEAL_SEAL;\n" "\\&\n" " if (fcntl(fd, F_ADD_SEALS, seals) == -1)\n" " err(EXIT_FAILURE, \"fcntl\");\n" " }\n" "\\&\n" " /* Continuer l’exécution pour que le fichier créé par\n" " memfd_create() continue à exister. */\n" "\\&\n" " pause();\n" "\\&\n" " exit(EXIT_SUCCESS);\n" "}\n" #. SRC END #. type: SS #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Program source: t_get_seals.c" msgstr "Source du programme : t_get_seals.c" #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed #, no-wrap msgid "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Efcntl.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "\\&\n" "int\n" "main(int argc, char *argv[])\n" "{\n" " int fd;\n" " unsigned int seals;\n" "\\&\n" " if (argc != 2) {\n" " fprintf(stderr, \"%s /proc/PID/fd/FD\\en\", argv[0]);\n" " exit(EXIT_FAILURE);\n" " }\n" "\\&\n" " fd = open(argv[1], O_RDWR);\n" " if (fd == -1)\n" " err(EXIT_FAILURE, \"open\");\n" "\\&\n" " seals = fcntl(fd, F_GET_SEALS);\n" " if (seals == -1)\n" " err(EXIT_FAILURE, \"fcntl\");\n" "\\&\n" " printf(\"Existing seals:\");\n" " if (seals & F_SEAL_SEAL)\n" " printf(\" SEAL\");\n" " if (seals & F_SEAL_GROW)\n" " printf(\" GROW\");\n" " if (seals & F_SEAL_WRITE)\n" " printf(\" WRITE\");\n" " if (seals & F_SEAL_FUTURE_WRITE)\n" " printf(\" FUTURE_WRITE\");\n" " if (seals & F_SEAL_SHRINK)\n" " printf(\" SHRINK\");\n" " printf(\"\\en\");\n" "\\&\n" " /* Code to map the file and access the contents of the\n" " resulting mapping omitted. */\n" "\\&\n" " exit(EXIT_SUCCESS);\n" "}\n" msgstr "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Efcntl.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "\\&\n" "int\n" "main(int argc, char *argv[])\n" "{\n" " int fd;\n" " unsigned int seals;\n" "\\&\n" " if (argc != 2) {\n" " fprintf(stderr, \"%s /proc/PID/fd/FD\\en\", argv[0]);\n" " exit(EXIT_FAILURE);\n" " }\n" "\\&\n" " fd = open(argv[1], O_RDWR);\n" " if (fd == -1)\n" " err(EXIT_FAILURE, \"open\");\n" "\\&\n" " seals = fcntl(fd, F_GET_SEALS);\n" " if (seals == -1)\n" " err(EXIT_FAILURE, \"fcntl\");\n" "\\&\n" " printf(\"Verrous existants :\");\n" " if (seals & F_SEAL_SEAL)\n" " printf(\" SEAL\");\n" " if (seals & F_SEAL_GROW)\n" " printf(\" GROW\");\n" " if (seals & F_SEAL_WRITE)\n" " printf(\" WRITE\");\n" " if (seals & F_SEAL_FUTURE_WRITE)\n" " printf(\" FUTURE_WRITE\");\n" " if (seals & F_SEAL_SHRINK)\n" " printf(\" SHRINK\");\n" " printf(\"\\en\");\n" "\\&\n" " /* Code pour associer le fichier et l'accès au contenu de la\n" " projection résultante omise. */\n" "\\&\n" " exit(EXIT_SUCCESS);\n" "}\n" #. SRC END #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "SEE ALSO" msgstr "VOIR AUSSI" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "B(2), B(2), B(2), B(2), B(2), " "B(3)" msgstr "" "B(2), B(2), B(2), B(2), B(2), " "B(3)" #. type: TH #: debian-bookworm #, no-wrap msgid "2023-02-05" msgstr "5 février 2023" #. type: TH #: debian-bookworm #, no-wrap msgid "Linux man-pages 6.03" msgstr "Pages du manuel de Linux 6.03" #. type: TP #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "B, B, B<...>" msgstr "B, B, B<...>" #. type: SH #: debian-bookworm #, no-wrap msgid "VERSIONS" msgstr "VERSIONS" #. type: Plain text #: debian-bookworm msgid "" "The B() system call first appeared in Linux 3.17; glibc " "support was added in glibc 2.27." msgstr "" "L'appel système B() est apparu dans Linux 3.17 ; la prise en " "charge de la glibc a été ajouté dans la glibc 2.27." #. type: Plain text #: debian-bookworm msgid "The B() system call is Linux-specific." msgstr "L'appel système B() est spécifique à Linux." #. type: Plain text #: debian-bookworm msgid "" "The second process opens the file IpidE/fd/EfdE>, " "where IpidE> is the PID of the first process (the one that called " "B()), and IfdE> is the number of the file descriptor " "returned by the call to B() in that process. The second " "process then maps the file using B(2)." msgstr "" "Le deuxième processus ouvre le fichier IpidE/fd/" "EfdE>, où IpidE> est l'identifiant de processus du premier " "processus (celui qui a appelé B()) et IfdE> est le " "numéro du descripteur de fichier renvoyé par l'appel à B dans " "ce processus. Le deuxième processus projette ensuite le fichier en utilisant " "B(2)." #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Efcntl.hE\n" "#include Estdint.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" "#include Esys/mman.hE\n" "#include Eunistd.hE\n" msgstr "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Efcntl.hE\n" "#include Estdint.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" "#include Esys/mman.hE\n" "#include Eunistd.hE\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "int\n" "main(int argc, char *argv[])\n" "{\n" " int fd;\n" " char *name, *seals_arg;\n" " ssize_t len;\n" " unsigned int seals;\n" msgstr "" "int\n" "main(int argc, char *argv[])\n" "{\n" " int fd;\n" " char *name, *seals_arg;\n" " ssize_t len;\n" " unsigned int seals;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (argc E 3) {\n" " fprintf(stderr, \"%s name size [seals]\\en\", argv[0]);\n" " fprintf(stderr, \"\\et\\[aq]seals\\[aq] can contain any of the \"\n" " \"following characters:\\en\");\n" " fprintf(stderr, \"\\et\\etg - F_SEAL_GROW\\en\");\n" " fprintf(stderr, \"\\et\\ets - F_SEAL_SHRINK\\en\");\n" " fprintf(stderr, \"\\et\\etw - F_SEAL_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etW - F_SEAL_FUTURE_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etS - F_SEAL_SEAL\\en\");\n" " exit(EXIT_FAILURE);\n" " }\n" msgstr "" " if (argc E 3) {\n" " fprintf(stderr, \"%s name size [seals]\\en\", argv[0]);\n" " fprintf(stderr, \"\\et\\[aq]seals\\[aq] peut contenir un des \"\n" " \"caractères suivants :\\en\");\n" " fprintf(stderr, \"\\et\\etg - F_SEAL_GROW\\en\");\n" " fprintf(stderr, \"\\et\\ets - F_SEAL_SHRINK\\en\");\n" " fprintf(stderr, \"\\et\\etw - F_SEAL_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etW - F_SEAL_FUTURE_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etS - F_SEAL_SEAL\\en\");\n" " exit(EXIT_FAILURE);\n" " }\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " name = argv[1];\n" " len = atoi(argv[2]);\n" " seals_arg = argv[3];\n" msgstr "" " name = argv[1];\n" " len = atoi(argv[2]);\n" " seals_arg = argv[3];\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " /* Create an anonymous file in tmpfs; allow seals to be\n" " placed on the file. */\n" msgstr "" " /* Créer un fichier anonyme dans tmpfs ; permet de poser\n" " des verrous sur le fichier. */\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " fd = memfd_create(name, MFD_ALLOW_SEALING);\n" " if (fd == -1)\n" " err(EXIT_FAILURE, \"memfd_create\");\n" msgstr "" " fd = memfd_create(name, MFD_ALLOW_SEALING);\n" " if (fd == -1)\n" " err(EXIT_FAILURE, \"memfd_create\");\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid " /* Size the file as specified on the command line. */\n" msgstr " /* Taille du fichier indiquée sur la ligne de commande. */\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (ftruncate(fd, len) == -1)\n" " err(EXIT_FAILURE, \"truncate\");\n" msgstr "" " if (ftruncate(fd, len) == -1)\n" " err(EXIT_FAILURE, \"truncate\");\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " printf(\"PID: %jd; fd: %d; /proc/%jd/fd/%d\\en\",\n" " (intmax_t) getpid(), fd, (intmax_t) getpid(), fd);\n" msgstr "" " printf(\"PID: %jd; fd: %d; /proc/%jd/fd/%d\\en\",\n" " (intmax_t) getpid(), fd, (intmax_t) getpid(), fd);\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " /* Code to map the file and populate the mapping with data\n" " omitted. */\n" msgstr "" " /* Code pour projeter le fichier et remplir la projection\n" " avec des données omises. */\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " /* If a \\[aq]seals\\[aq] command-line argument was supplied, set some\n" " seals on the file. */\n" msgstr "" " /* Si un paramètre \\[aq]seals\\[aq] de la ligne de commande est fourni,\n" " poser des verrous sur le fichier. */\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (seals_arg != NULL) {\n" " seals = 0;\n" msgstr "" " if (seals_arg != NULL) {\n" " seals = 0;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (strchr(seals_arg, \\[aq]g\\[aq]) != NULL)\n" " seals |= F_SEAL_GROW;\n" " if (strchr(seals_arg, \\[aq]s\\[aq]) != NULL)\n" " seals |= F_SEAL_SHRINK;\n" " if (strchr(seals_arg, \\[aq]w\\[aq]) != NULL)\n" " seals |= F_SEAL_WRITE;\n" " if (strchr(seals_arg, \\[aq]W\\[aq]) != NULL)\n" " seals |= F_SEAL_FUTURE_WRITE;\n" " if (strchr(seals_arg, \\[aq]S\\[aq]) != NULL)\n" " seals |= F_SEAL_SEAL;\n" msgstr "" " if (strchr(seals_arg, \\[aq]g\\[aq]) != NULL)\n" " seals |= F_SEAL_GROW;\n" " if (strchr(seals_arg, \\[aq]s\\[aq]) != NULL)\n" " seals |= F_SEAL_SHRINK;\n" " if (strchr(seals_arg, \\[aq]w\\[aq]) != NULL)\n" " seals |= F_SEAL_WRITE;\n" " if (strchr(seals_arg, \\[aq]W\\[aq]) != NULL)\n" " seals |= F_SEAL_FUTURE_WRITE;\n" " if (strchr(seals_arg, \\[aq]S\\[aq]) != NULL)\n" " seals |= F_SEAL_SEAL;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (fcntl(fd, F_ADD_SEALS, seals) == -1)\n" " err(EXIT_FAILURE, \"fcntl\");\n" " }\n" msgstr "" " if (fcntl(fd, F_ADD_SEALS, seals) == -1)\n" " err(EXIT_FAILURE, \"fcntl\");\n" " }\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " /* Keep running, so that the file created by memfd_create()\n" " continues to exist. */\n" msgstr "" " /* Continuer l’exécution pour que le fichier créé par\n" " memfd_create() continue à exister. */\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid " pause();\n" msgstr " pause();\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " exit(EXIT_SUCCESS);\n" "}\n" msgstr "" " exit(EXIT_SUCCESS);\n" "}\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Efcntl.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" msgstr "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Efcntl.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "int\n" "main(int argc, char *argv[])\n" "{\n" " int fd;\n" " unsigned int seals;\n" msgstr "" "int\n" "main(int argc, char *argv[])\n" "{\n" " int fd;\n" " unsigned int seals;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (argc != 2) {\n" " fprintf(stderr, \"%s /proc/PID/fd/FD\\en\", argv[0]);\n" " exit(EXIT_FAILURE);\n" " }\n" msgstr "" " if (argc != 2) {\n" " fprintf(stderr, \"%s /proc/PID/fd/FD\\en\", argv[0]);\n" " exit(EXIT_FAILURE);\n" " }\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " fd = open(argv[1], O_RDWR);\n" " if (fd == -1)\n" " err(EXIT_FAILURE, \"open\");\n" msgstr "" " fd = open(argv[1], O_RDWR);\n" " if (fd == -1)\n" " err(EXIT_FAILURE, \"open\");\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " seals = fcntl(fd, F_GET_SEALS);\n" " if (seals == -1)\n" " err(EXIT_FAILURE, \"fcntl\");\n" msgstr "" " seals = fcntl(fd, F_GET_SEALS);\n" " if (seals == -1)\n" " err(EXIT_FAILURE, \"fcntl\");\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " printf(\"Existing seals:\");\n" " if (seals & F_SEAL_SEAL)\n" " printf(\" SEAL\");\n" " if (seals & F_SEAL_GROW)\n" " printf(\" GROW\");\n" " if (seals & F_SEAL_WRITE)\n" " printf(\" WRITE\");\n" " if (seals & F_SEAL_FUTURE_WRITE)\n" " printf(\" FUTURE_WRITE\");\n" " if (seals & F_SEAL_SHRINK)\n" " printf(\" SHRINK\");\n" " printf(\"\\en\");\n" msgstr "" " printf(\"Verrous existants :\");\n" " if (seals & F_SEAL_SEAL)\n" " printf(\" SEAL\");\n" " if (seals & F_SEAL_GROW)\n" " printf(\" GROW\");\n" " if (seals & F_SEAL_WRITE)\n" " printf(\" WRITE\");\n" " if (seals & F_SEAL_FUTURE_WRITE)\n" " printf(\" FUTURE_WRITE\");\n" " if (seals & F_SEAL_SHRINK)\n" " printf(\" SHRINK\");\n" " printf(\"\\en\");\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " /* Code to map the file and access the contents of the\n" " resulting mapping omitted. */\n" msgstr "" " /* Code pour associer le fichier et l'accès au contenu de la\n" " projection résultante omise. */\n" #. type: TH #: fedora-40 fedora-rawhide mageia-cauldron #, no-wrap msgid "2023-10-31" msgstr "31 octobre 2023" #. type: TH #: fedora-40 mageia-cauldron #, no-wrap msgid "Linux man-pages 6.06" msgstr "Pages du manuel de Linux 6.06" #. type: Plain text #: fedora-40 fedora-rawhide mageia-cauldron #, no-wrap msgid "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Efcntl.hE\n" "#include Estdint.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" "#include Esys/mman.hE\n" "#include Eunistd.hE\n" "\\&\n" "int\n" "main(int argc, char *argv[])\n" "{\n" " int fd;\n" " char *name, *seals_arg;\n" " ssize_t len;\n" " unsigned int seals;\n" "\\&\n" " if (argc E 3) {\n" " fprintf(stderr, \"%s name size [seals]\\en\", argv[0]);\n" " fprintf(stderr, \"\\et\\[aq]seals\\[aq] can contain any of the \"\n" " \"following characters:\\en\");\n" " fprintf(stderr, \"\\et\\etg - F_SEAL_GROW\\en\");\n" " fprintf(stderr, \"\\et\\ets - F_SEAL_SHRINK\\en\");\n" " fprintf(stderr, \"\\et\\etw - F_SEAL_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etW - F_SEAL_FUTURE_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etS - F_SEAL_SEAL\\en\");\n" " exit(EXIT_FAILURE);\n" " }\n" "\\&\n" " name = argv[1];\n" " len = atoi(argv[2]);\n" " seals_arg = argv[3];\n" "\\&\n" " /* Create an anonymous file in tmpfs; allow seals to be\n" " placed on the file. */\n" "\\&\n" " fd = memfd_create(name, MFD_ALLOW_SEALING);\n" " if (fd == -1)\n" " err(EXIT_FAILURE, \"memfd_create\");\n" "\\&\n" " /* Size the file as specified on the command line. */\n" "\\&\n" " if (ftruncate(fd, len) == -1)\n" " err(EXIT_FAILURE, \"truncate\");\n" "\\&\n" " printf(\"PID: %jd; fd: %d; /proc/%jd/fd/%d\\en\",\n" " (intmax_t) getpid(), fd, (intmax_t) getpid(), fd);\n" "\\&\n" " /* Code to map the file and populate the mapping with data\n" " omitted. */\n" "\\&\n" " /* If a \\[aq]seals\\[aq] command-line argument was supplied, set some\n" " seals on the file. */\n" "\\&\n" " if (seals_arg != NULL) {\n" " seals = 0;\n" "\\&\n" " if (strchr(seals_arg, \\[aq]g\\[aq]) != NULL)\n" " seals |= F_SEAL_GROW;\n" " if (strchr(seals_arg, \\[aq]s\\[aq]) != NULL)\n" " seals |= F_SEAL_SHRINK;\n" " if (strchr(seals_arg, \\[aq]w\\[aq]) != NULL)\n" " seals |= F_SEAL_WRITE;\n" " if (strchr(seals_arg, \\[aq]W\\[aq]) != NULL)\n" " seals |= F_SEAL_FUTURE_WRITE;\n" " if (strchr(seals_arg, \\[aq]S\\[aq]) != NULL)\n" " seals |= F_SEAL_SEAL;\n" "\\&\n" " if (fcntl(fd, F_ADD_SEALS, seals) == -1)\n" " err(EXIT_FAILURE, \"fcntl\");\n" " }\n" "\\&\n" " /* Keep running, so that the file created by memfd_create()\n" " continues to exist. */\n" "\\&\n" " pause();\n" "\\&\n" " exit(EXIT_SUCCESS);\n" "}\n" msgstr "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Efcntl.hE\n" "#include Estdint.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" "#include Esys/mman.hE\n" "#include Eunistd.hE\n" "\\&\n" "int\n" "main(int argc, char *argv[])\n" "{\n" " int fd;\n" " char *name, *seals_arg;\n" " ssize_t len;\n" " unsigned int seals;\n" "\\&\n" " if (argc E 3) {\n" " fprintf(stderr, \"%s name size [seals]\\en\", argv[0]);\n" " fprintf(stderr, \"\\et\\[aq]seals\\[aq] peut contenir un des \"\n" " \"caractères suivants :\\en\");\n" " fprintf(stderr, \"\\et\\etg - F_SEAL_GROW\\en\");\n" " fprintf(stderr, \"\\et\\ets - F_SEAL_SHRINK\\en\");\n" " fprintf(stderr, \"\\et\\etw - F_SEAL_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etW - F_SEAL_FUTURE_WRITE\\en\");\n" " fprintf(stderr, \"\\et\\etS - F_SEAL_SEAL\\en\");\n" " exit(EXIT_FAILURE);\n" " }\n" "\\&\n" " name = argv[1];\n" " len = atoi(argv[2]);\n" " seals_arg = argv[3];\n" "\\&\n" " /* Créer un fichier anonyme dans tmpfs ; permet de poser\n" " des verrous sur le fichier. */\n" "\\&\n" " fd = memfd_create(name, MFD_ALLOW_SEALING);\n" " if (fd == -1)\n" " err(EXIT_FAILURE, \"memfd_create\");\n" "\\&\n" " /* Taille du fichier indiquée sur la ligne de commande. */\n" "\\&\n" " if (ftruncate(fd, len) == -1)\n" " err(EXIT_FAILURE, \"truncate\");\n" "\\&\n" " printf(\"PID: %jd; fd: %d; /proc/%jd/fd/%d\\en\",\n" " (intmax_t) getpid(), fd, (intmax_t) getpid(), fd);\n" "\\&\n" " /* Code pour projeter le fichier et remplir la projection\n" " avec des données omises. */\n" "\\&\n" " /* Si un paramètre \\[aq]seals\\[aq] de la ligne de commande est fourni,\n" " poser des verrous sur le fichier. */\n" "\\&\n" " if (seals_arg != NULL) {\n" " seals = 0;\n" "\\&\n" " if (strchr(seals_arg, \\[aq]g\\[aq]) != NULL)\n" " seals |= F_SEAL_GROW;\n" " if (strchr(seals_arg, \\[aq]s\\[aq]) != NULL)\n" " seals |= F_SEAL_SHRINK;\n" " if (strchr(seals_arg, \\[aq]w\\[aq]) != NULL)\n" " seals |= F_SEAL_WRITE;\n" " if (strchr(seals_arg, \\[aq]W\\[aq]) != NULL)\n" " seals |= F_SEAL_FUTURE_WRITE;\n" " if (strchr(seals_arg, \\[aq]S\\[aq]) != NULL)\n" " seals |= F_SEAL_SEAL;\n" "\\&\n" " if (fcntl(fd, F_ADD_SEALS, seals) == -1)\n" " err(EXIT_FAILURE, \"fcntl\");\n" " }\n" "\\&\n" " /* Continuer l’exécution pour que le fichier créé par\n" " memfd_create() continue à exister. */\n" "\\&\n" " pause();\n" "\\&\n" " exit(EXIT_SUCCESS);\n" "}\n" #. type: TH #: fedora-rawhide #, no-wrap msgid "Linux man-pages 6.7" msgstr "Pages du manuel de Linux 6.7" #. type: TH #: opensuse-leap-15-6 #, no-wrap msgid "2023-04-03" msgstr "3 avril 2023" #. type: TH #: opensuse-leap-15-6 #, no-wrap msgid "Linux man-pages 6.04" msgstr "Pages du manuel de Linux 6.04" #. type: TH #: opensuse-tumbleweed #, no-wrap msgid "Linux man-pages (unreleased)" msgstr "Pages du manuel de Linux (non publiées)"