This repository has been archived by the owner on Nov 21, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
53 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,35 @@ | ||
#define TAR "ustar\000" | ||
#define GNUTAR "GNUtar\00" | ||
//TODO: 64-bit number versions with conditional compile option | ||
|
||
#define TAR32L 0x61747375 | ||
#define TAR32H 0x00202072 | ||
#define TAR32H 0x30300072 | ||
#define TAR64 0x3030007261747375LU | ||
|
||
#define GNUTAR32L 0x74554E47 | ||
#define GNUTAR32H 0x20007261 | ||
#define GNUTAR32H 0x30007261 | ||
#define GNUTAR64 0x3000726174554E47LU | ||
|
||
#define NAMSIZ 100 | ||
#define TUNMLEN 32 | ||
#define TGNMLEN 32 | ||
|
||
struct tar_hdr { | ||
char name[NAMSIZ]; | ||
struct tar_hdr { // POSIX 1003.1-1990 | ||
char name[100]; | ||
char mode[8]; | ||
char uid[8]; | ||
char gid[8]; | ||
char size[12]; | ||
char mtime[12]; | ||
char chksum[8]; | ||
char linkflag; | ||
char linkname[NAMSIZ]; | ||
char magic[8]; | ||
char uname[TUNMLEN]; | ||
char gname[TGNMLEN]; | ||
char typeflag; | ||
char linkname[100]; | ||
char magic[6]; | ||
char version[2]; | ||
char uname[32]; | ||
char gname[32]; | ||
char devmajor[8]; | ||
char devminor[8]; | ||
// char prefix[155]; | ||
}; | ||
|
||
void scan_tar(void); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters