---
title: "TarHeader"
source: "https://github.com/remix-run/remix/blob/8905f3943706e1f53696ab83e70a84873cabfc90/packages/tar-parser/src/lib/tar.ts#L70"
---

# TarHeader

## Summary

The parsed header of a tar entry.

## Signature

```ts
interface TarHeader {
  devmajor: number | null
  devminor: number | null
  gid: number | null
  gname: string
  linkname: string | null
  mode: number | null
  mtime: number | null
  name: string
  pax: Record<string, string> | null
  size: number
  type: string
  uid: number | null
  uname: string
}

```

## Properties

### `devmajor`

Major device number for device entries, or `null` when unavailable.

### `devminor`

Minor device number for device entries, or `null` when unavailable.

### `gid`

Numeric group ID parsed from the header, or `null` when unavailable.

### `gname`

Group name parsed from the header.

### `linkname`

Linked path target for link entries, or `null` when not present.
By default, symlink targets must stay within the archive when resolved relative to the
link's parent, and hard-link targets when resolved relative to the archive root.
Targets retain their relative spelling. Filesystem containment still requires consumer
validation. The `preserve` path policy disables target checks.

### `mode`

File mode parsed from the header, or `null` when unavailable.

### `mtime`

Last modification time parsed from the header, or `null` when unavailable.

### `name`

Entry path stored in the archive.
By default, parsed names are relative paths without parent components, Windows drive
prefixes, backslashes, or NULs. The `preserve` path policy disables these checks.
Filesystem containment still requires consumer validation.

### `pax`

Decoded PAX metadata attached to the entry, or `null` when none is present.

### `size`

Entry size in bytes. Parsed sizes are non-negative safe integers.

### `type`

Normalized entry type such as `file` or `directory`.

### `uid`

Numeric user ID parsed from the header, or `null` when unavailable.

### `uname`

User name parsed from the header.