Commit Graph

363 Commits (208788de28150f1ceba5fbfa2f3fc5f191ac3258)

Author SHA1 Message Date
Dustin Oprea 208788de28 go.mod: Drop go-utility replacement and update sums 2020-07-11 14:06:20 -04:00
Dustin Oprea 32eff3cfee .travis.yml: Switch to codecov.io 2020-07-11 13:47:13 -04:00
Dustin Oprea 9e26737f70 .travis.yml: Fix CI for v2 2020-07-11 13:39:08 -04:00
Dustin Oprea 3ee774b832 README.md: Update for v3 2020-07-11 13:37:28 -04:00
Dustin Oprea d19e38a723 backwards incompatible: ifd_enumerate.go: Drop fqIfdPath and ifdIndex from visitor function signature 2020-07-11 13:15:18 -04:00
Dustin Oprea f2c3d1c0ec backwards incompatible: ifd_enumerate.go: Stop exporting Ifd fields
Finally.
2020-07-11 13:15:18 -04:00
Dustin Oprea dcd29a9733 backwards incompatible: Move exif-read-tool to command/
Per standard practice.
2020-07-11 13:15:18 -04:00
Dustin Oprea 7ca1c7b13e backwards incompatible: GetFlatExifData(), Scan(), and Visit() all take a ScanOptions struct now 2020-07-11 13:15:18 -04:00
Dustin Oprea 3f7ee4ce89 backwards incompatible: Move time utilities to exifcommon 2020-07-11 13:15:18 -04:00
Dustin Oprea 83b844408c backwards incompatible: Stop exporting ParseOneIfd and ParseOneTag 2020-07-11 13:15:18 -04:00
Dustin Oprea ee26db1fc4 backwards incompatible: Drop redundant variables 2020-07-11 13:15:18 -04:00
Dustin Oprea 7d4721b065 backwards incompatible: Removed bridging functions
NewIfdMappingWithStandard and related (in ifd.go). We now use the same
functions in common/.

- NewIfdMappingWithStandard now returns an error, too.

This took care of several backwards-incompatible tasks that have been
waiting on v3 to be forked.
2020-07-11 13:15:12 -04:00
Dustin Oprea 4e059a6b95 Drop inline RELEASE TO-DOs from v2. They are now active tasks in v3. 2020-07-11 12:12:48 -04:00
Dustin Oprea 17a2176005 v2/v3: Bump go-logging version to latest 2020-07-11 12:12:48 -04:00
Dustin Oprea f76918441c .travis.yml: Add CI for v3 2020-07-11 12:12:48 -04:00
Dustin Oprea 312218d7b1 Use encapsulated data/reader rather than bytes
Given a stream of data, it is possible to determine the beginning of
EXIF data but not the end. Therefore, either an image-aware
implementation must know how to parse an image and extract the EXIF
data or a brute-force search implementation (one of which is provided
by this project) must find the start anchor and then return all bytes
from that to the end of the file.

We have been made aware of some use-cases where a brute-force search
might be unavoidable due to trust or stability issues with the image
structure. This leads to large allocations. This can be avoided by
accomodating support that will allow for both a byte-slice or an
`io.ReadSeeker`. Since the EXIF structure is typically not read-
intensive (a couple of kilobytes if no thumbnail is present), this
should have a minimal performance impact.

Closes #42
2020-07-11 12:12:48 -04:00
Dustin Oprea 56058635d0 Seed v3 release. Copy from v2 release. 2020-07-11 12:12:48 -04:00
Dustin Oprea e0ce96b49e Revert "Revert "ifd_enumerate.go: Eliminate unnecessary buffering""
This reverts commit 3bd3dd677b.

Includes fixes.
2020-07-09 22:01:27 -04:00
Dustin Oprea 3bd3dd677b Revert "ifd_enumerate.go: Eliminate unnecessary buffering"
This reverts commit 4692087c1a.

Broke unit-tests. Will unbreak shortly.
2020-07-09 16:19:38 -04:00
Dustin Oprea 4692087c1a ifd_enumerate.go: Eliminate unnecessary buffering
A simplification prior to some upcoming data-access changes.
2020-07-09 16:07:46 -04:00
Dustin Oprea 5a15f40e78 exif-read-tool/main.go: Tweak help message 2020-07-03 10:55:30 -04:00
Dustin Oprea 1b5ecc84b1 README.md: Tweak contribution verbiage 2020-06-12 02:38:33 -04:00
Dustin Oprea bd92d354b0 Minor report-card fixes in v1 2020-06-12 02:22:22 -04:00
Dustin Oprea 4e9bef94e7 .travis.yml: Add builds for 1.14 2020-06-12 02:13:50 -04:00
Dustin Oprea bd6037a0b8 Bugfixes to previous report-card fixes 2020-06-12 02:13:50 -04:00
Dustin Oprea 9743a98845 Revert "Revert "Report-card fixes""
This reverts commit 4450f89e048a2373cd82a911725b6c54d22632eb.

The next commit has the fixes.
2020-06-12 02:13:36 -04:00
Dustin Oprea 591504aef0 Revert "Report-card fixes"
This reverts commit eb5bd13c98.

Introduced some new issues, here. This is being debugged on a separate
branch.

Fixes #41
2020-06-12 01:52:09 -04:00
Dustin Oprea 82fe0e20b9 Add dataset attribution to Michael Rubin 2020-06-10 16:23:04 -04:00
Dustin Oprea 9fa7bb0066 README.md: Add mention of other supported image-formats 2020-06-10 16:15:57 -04:00
Dustin Oprea 519e825052 README.md: Add score-card badge 2020-06-10 16:15:44 -04:00
Dustin Oprea eb5bd13c98 Report-card fixes 2020-06-10 16:11:13 -04:00
Dustin Oprea 7edf52b885 Timestamps can now be set directly 2020-06-07 01:33:12 -04:00
Dustin Oprea d69a43ee6a common/testing_common.go: Bugfix for empty module-path introduced by recent commit 2020-06-07 00:55:05 -04:00
Dustin Oprea e50deb910e main_test.go: Do not pre-cache values from init() in tests 2020-06-07 00:51:43 -04:00
Dustin Oprea ca8584a0e1 Minor sensible testing refactors 2020-06-04 15:34:36 -04:00
Dustin Oprea a350bacdac exif.go: Use constant symbol rather than literal 2020-06-04 01:37:20 -04:00
Dustin Oprea 7a76510c2b Revert "Refactor module-detection to use go/build instead of static file"
This reverts commit c23f7a1066.

The package-path will be a build-path rather than a source-path, and any
assets being referred to will not be found.
2020-06-04 01:37:15 -04:00
Dustin Oprea eb6d1c16a5 Revert "common/testing_common.go: Bugfix for package-path finder"
This reverts commit 77cb76cd34.

The package-path will be a build-path rather than a source-path, and any
assets being referred to will not be found.
2020-06-04 01:35:32 -04:00
Dustin Oprea 77cb76cd34 common/testing_common.go: Bugfix for package-path finder 2020-06-02 15:01:38 -04:00
Dustin Oprea c23f7a1066 Refactor module-detection to use go/build instead of static file 2020-06-02 04:23:08 -04:00
Dustin Oprea e46688a494 .travis.yml: Bugfix for no module support in CI
Tip of dependency is broken and it was affecting us:

https://github.com/go-errors/errors/issues/27

- We also disabled 1.10 and 1.11 due to lack of support in dependencies now that we're being recognized as a module.
2020-06-01 01:33:14 -04:00
Dustin Oprea 87d01d1392 Revert ".travis.yml: Disable V1 CI. Dependencies currently broken and this version is very legacy and very unsupported."
This reverts commit d1728617c7.

Not having desired effect.
2020-06-01 00:28:09 -04:00
Dustin Oprea d1728617c7 .travis.yml: Disable V1 CI. Dependencies currently broken and this version is very legacy and very unsupported.
https://github.com/go-errors/errors/issues/27
2020-06-01 00:21:43 -04:00
Dustin Oprea a06d9b9e40 ifd_tag_entry.go: Bugfix for GetRawBytes() mishandling error from exifundefined.Decode()
if `Decode()` returns `exifcommon.ErrUnhandledUndefinedTypedTag` it just
falls through, but should have been returning
`exifundefined.ErrUnparseableValue`.

- Also, `GetRawBytes()` was missing the recover clause for blanket error
  handler.
2020-05-31 11:14:09 -04:00
Dustin Oprea 1a62daf305 ifd.go: Moved implementations of IfdMapping and LoadStandardIfds to exifcommon.ifd
In lieu of dropping in next release. We needed this in order to write
some unit-tests for exifcommon functionality, and this is common
functionality anyway (by any definition of common thus far).

- common/ifd.go: Added NewIfdIdentityFromString. The above allowed us to
  cover this with unit-tests.
  - This was required for go-exif-knife, to get IFD-paths from the
    command-line.
2020-05-27 12:50:02 -04:00
Dustin Oprea 2a1e3f0fa1 ifd_enumerate.go: Add call to postparseTag() after parseTag() in ParseOneTag()
- Should have been in previous
2020-05-27 00:29:08 -04:00
Dustin Oprea fb98f429ee We now guess at alternative IFDs for invalid tags automatically
This required some backtracking on a change we just pushed a little
while ago.
2020-05-27 00:29:03 -04:00
Dustin Oprea b4c2ca5765 tags.go: Bugfix for bad FindFirst() error handling and not returning if not found
- utility.go: Add GetExifData() to return flat tags and extra data and
  to allow guessing of tags for misplaced IFDs.

- exif-read-tool/main.go: Implement tag guessing
2020-05-26 21:28:27 -04:00
Dustin Oprea df74da8384 tags_data.go: Drop non-standard tags having non-standard, undocumented types 2020-05-26 21:14:23 -04:00
Dustin Oprea de4b8921bd Log guesses about implementation incongruities for invalid tags
2020/05/25 19:21:33 exif.utility: [WARNING]  Tag with ID (0x0201) in IFD [IFD/Exif] is not recognized and will be ignored.
2020/05/25 19:21:33 exif.utility: [WARNING]  (cont'd) Tag [JPEGInterchangeFormat] with the same ID has been found in IFD [IFD] and may be related. The tag you were looking for might have been written to the wrong IFD by a buggy implementation.
2020/05/25 19:21:33 exif.utility: [WARNING]  Tag with ID (0x0202) in IFD [IFD/Exif] is not recognized and will be ignored.
2020/05/25 19:21:33 exif.utility: [WARNING]  (cont'd) Tag [JPEGInterchangeFormatLength] with the same ID has been found in IFD [IFD] and may be related. The tag you were looking for might have been written to the wrong IFD by a buggy implementation.

Closes #38
2020-05-25 19:22:47 -04:00