diff --git a/LICENSE b/LICENSE index b847234..ed07404 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright © 2023 traperto GmbH +Copyright © 2024 traperto GmbH Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: diff --git a/MagicBytesValidator/MagicBytesValidator.csproj b/MagicBytesValidator/MagicBytesValidator.csproj index 93a2a5c..57abc97 100644 --- a/MagicBytesValidator/MagicBytesValidator.csproj +++ b/MagicBytesValidator/MagicBytesValidator.csproj @@ -3,9 +3,9 @@ MagicBytesValidator traperto GmbH - Validate files based on mimetypes, extensions and magicbytes. - 2.0.1 - Members of traperto gmbh + Validate files based on mime types, file extensions and magic byte sequences. + 2.0.2 + Members of traperto GmbH https://github.com/Traperto/magic-bytes-validator/blob/main/README.md mime mimetype mimetypes magic magicbyte magicbytes extension extensions file fileextension traperto trapertoGmbh diff --git a/README.md b/README.md index b50081e..5c38b85 100644 --- a/README.md +++ b/README.md @@ -7,16 +7,16 @@ The existing `FileTypes` can be expanded in various ways. - Install nuget package into your project: ```powershell -Install-Package MagicBytesValidator -Version 2.0.0 +Install-Package MagicBytesValidator -Version 2.0.2 ``` ```bash -dotnet add package MagicBytesValidator --version 2.0.0 +dotnet add package MagicBytesValidator --version 2.0.2 ``` - Reference in your csproj: ```xml - + ``` ### How to use it? @@ -132,41 +132,41 @@ This can be useful when debugging or validating newly added FileTypes. ### List of Filetypes -| Mimetype | Extension | Magicbytes (decimal) | -|-------------------------------------------------|--------------------------------------------|----------------------------------------------------------------------------------------------------------------------------| -| audio/x-pn-realaudio-plugin | rpm | 237 171 238 219 | -| application/octet-stream | bin
file
com
class
ini |
  • 83 80 48 49
  • 201
  • 202 254 186 190
| -| video/3gpp | 3gp | 102 116 121 112 51 103 | -| image/x-icon | ico | 0 0 1 0 | -| image/gif | gif |
  • 71 73 70 56 55 97
  • 71 73 70 56 57 97
| -| image/tiff | tif
tiff |
  • 73 73 42 0
  • 77 77 0 42
| +| Mimetype | Extension | Magicbytes (decimal) | +|-------------------------------------------------|--------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------| +| audio/x-pn-realaudio-plugin | rpm | 237 171 238 219 | +| application/octet-stream | bin
file
com
class
ini |
  • 83 80 48 49
  • 201
  • 202 254 186 190
| +| video/3gpp | 3gp | 102 116 121 112 51 103 | +| image/x-icon | ico | 0 0 1 0 | +| image/gif | gif |
  • 71 73 70 56 55 97
  • 71 73 70 56 57 97
| +| image/tiff | tif
tiff |
  • 73 73 42 0
  • 77 77 0 42
| | image/jpeg | jpg
jpeg
jpe |
  • 255 216 255 219
  • 255 216 255 224 0 16 74
  • 70 73 70 0 1
  • 255 216 255 238
  • 105 102 0 0
| -| image/png | png | 137 80 78 71 13 10 26 10 | -| video/ogg | ogg
ogv | 79 103 103 83 | -| audio/basic | snd
au |
  • 56 83 86 88
  • 65 73 70 70
| -| application/dsptype | tsp | 77 90 | -| text/plain | txt |
  • 239 187 191
  • 255 254
  • 254 255
  • 255 254 0 0
| -| application/zip | zip | 80 75 3 4 | -| application | docx
xlsx | 80 75 7 8 | -| application/vnd.oasis.opendocument.presentation | odp | 80 75 7 8 | -| application/vnd.oasis.opendocument.spreadsheet | ods | 80 75 7 8 | -| application/vnd.oasis.opendocument.text | odt | 80 75 7 8 | -| audio/mpeg | mp3 | 73 68 51 | -| image/bmp | bmp | 66 77 | -| audio/x-midi | midi
mid | 77 84 104 100 | -| application/msword | doc
dot | 208 207 17 224 161 177 26 255 | -| application/msexcel | xlx
xla | 208 207 17 224 161 177 26 255 | -| application/mspowerpoint | ppt
ppz
pps
pt | 208 207 17 224 161 177 26 225 | -| application/gzip | gz | 31 139 | -| video/webm | webm | 26 69 223 163 | -| application/rtf | rtf | 123 92 114 116 102 49 | -| text/tab-separated-values | tsv | 71 | -| video/mpeg | mpg
mpeg
mpe |
  • 71
  • 0 0 1 186
  • 0 0 1 179
| -| video/mp4 | mp4 |
  • 102 116 121 112 105 115 111 109
  • 102 116 121 112 109 112 52 50
  • 102 116 121 112 77 83 62 86
| -| image/x-portable-bitmap | pbm | 80 49 10 | -| image/x-portable-graymap | pgm | 80 50 10 | -| image/x-portable-pixmap | ppm | 80 51 10 | -| application/pdf | pdf | 25 50 44 46 | +| image/png | png | 137 80 78 71 13 10 26 10 | +| video/ogg | ogg
ogv | 79 103 103 83 | +| audio/basic | snd
au |
  • 56 83 86 88
  • 65 73 70 70
| +| application/dsptype | tsp | 77 90 | +| text/plain | txt |
  • 239 187 191
  • 255 254
  • 254 255
  • 255 254 0 0
| +| application/zip | zip | 80 75 3 4 | +| application | docx
xlsx | 80 75 7 8 | +| application/vnd.oasis.opendocument.presentation | odp | 80 75 7 8 | +| application/vnd.oasis.opendocument.spreadsheet | ods | 80 75 7 8 | +| application/vnd.oasis.opendocument.text | odt | 80 75 7 8 | +| audio/mpeg | mp3 | 73 68 51 | +| image/bmp | bmp | 66 77 | +| audio/x-midi | midi
mid | 77 84 104 100 | +| application/msword | doc
dot | 208 207 17 224 161 177 26 255 | +| application/msexcel | xlx
xla | 208 207 17 224 161 177 26 255 | +| application/mspowerpoint | ppt
ppz
pps
pt | 208 207 17 224 161 177 26 225 | +| application/gzip | gz | 31 139 | +| video/webm | webm | 26 69 223 163 | +| application/rtf | rtf | 123 92 114 116 102 49 | +| text/tab-separated-values | tsv | 71 | +| video/mpeg | mpg
mpeg
mpe |
  • 71
  • 0 0 1 186
  • 0 0 1 179
| +| video/mp4 | mp4 |
  • 102 116 121 112 105 115 111 109
  • 102 116 121 112 109 112 52 50
  • 102 116 121 112 77 83 62 86
| +| image/x-portable-bitmap | pbm | 80 49 10 | +| image/x-portable-graymap | pgm | 80 50 10 | +| image/x-portable-pixmap | ppm | 80 51 10 | +| application/pdf | pdf | _multiple_ | ### What is the licence?