Commit graph

1043 commits

Author SHA1 Message Date
852939bb82
Merge pull request #275 from wneessen/dependabot/github_actions/github/codeql-action-3.26.0
Bump github/codeql-action from 3.25.15 to 3.26.0
2024-08-07 16:49:20 +02:00
dependabot[bot]
45c041f4fa
Bump actions/upload-artifact from 4.3.5 to 4.3.6
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4.3.5 to 4.3.6.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](89ef406dd8...834a144ee9)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-08-07 13:43:34 +00:00
dependabot[bot]
ab9aa2b46f
Bump github/codeql-action from 3.25.15 to 3.26.0
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.25.15 to 3.26.0.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](afb54ba388...eb055d739a)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-08-07 13:43:31 +00:00
85585eaabd
Merge pull request #274 from wneessen/dependabot/github_actions/step-security/harden-runner-2.9.1
Bump step-security/harden-runner from 2.9.0 to 2.9.1
2024-08-06 16:14:20 +02:00
dependabot[bot]
a80447d2be
Bump step-security/harden-runner from 2.9.0 to 2.9.1
Bumps [step-security/harden-runner](https://github.com/step-security/harden-runner) from 2.9.0 to 2.9.1.
- [Release notes](https://github.com/step-security/harden-runner/releases)
- [Commits](0d381219dd...5c7944e73c)

---
updated-dependencies:
- dependency-name: step-security/harden-runner
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-08-06 13:36:40 +00:00
1e0b7d0c78
Merge pull request #273 from wneessen/dependabot/github_actions/actions/upload-artifact-4.3.5
Bump actions/upload-artifact from 4.3.4 to 4.3.5
2024-08-05 16:08:22 +02:00
dependabot[bot]
a1ca73fb31
Bump actions/upload-artifact from 4.3.4 to 4.3.5
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4.3.4 to 4.3.5.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](0b2256b8c0...89ef406dd8)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-08-05 14:04:31 +00:00
f701b233be
Merge pull request #272 from wneessen/bug/271_parsing-rfc5322-example-a11-fails
Refactor: Handle missing Content-Type as plain text
2024-08-02 15:39:23 +02:00
69b1dc2359
Refactor: Handle missing Content-Type as plain text
Added a new example email and modified tests to include an RFC 5322 format. Refactored the code to handle cases where the Content-Type header is missing by defaulting to plain text (7bit, US-ASCII). Deleted redundant test cases that no longer apply.
2024-08-02 15:30:46 +02:00
3ca2968158
Merge pull request #270 from wneessen/feature/262_support-7bit-encoding
Add 7bit support for EML parsing
2024-08-01 11:06:35 +02:00
ed93e51cec
Add support for 7bit and 8bit encodings in EML parsing
Enhanced EML parsing to handle 7bit and 8bit content transfer encodings. Updated related test cases to verify the correct handling of these encodings. This ensures compliance with RFC2045 for defaulting to 7bit when no encoding is specified.
2024-08-01 10:55:28 +02:00
a28cf14efd
Add support for US-ASCII (7bit) encoding
Implemented a new encoding type, `EncodingUSASCII`, representing US-ASCII (7bit) encoding. Updated the test suite to include this new encoding in the test cases, ensuring proper validation and coverage.
2024-08-01 10:54:42 +02:00
b4acaf1406
Merge pull request #267 from wneessen/dependabot/github_actions/golangci/golangci-lint-action-6.1.0
Bump golangci/golangci-lint-action from 6.0.1 to 6.1.0
2024-07-30 16:08:48 +02:00
dependabot[bot]
cd91fbd777
Bump golangci/golangci-lint-action from 6.0.1 to 6.1.0
Bumps [golangci/golangci-lint-action](https://github.com/golangci/golangci-lint-action) from 6.0.1 to 6.1.0.
- [Release notes](https://github.com/golangci/golangci-lint-action/releases)
- [Commits](a4f60bb28d...aaa42aa062)

---
updated-dependencies:
- dependency-name: golangci/golangci-lint-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-30 13:54:10 +00:00
95bd224acd
Merge pull request #265 from wneessen/dependabot/github_actions/github/codeql-action-3.25.15
Bump github/codeql-action from 3.25.14 to 3.25.15
2024-07-29 15:41:51 +02:00
b730e458a4
Merge pull request #266 from wneessen/dependabot/github_actions/ossf/scorecard-action-2.4.0
Bump ossf/scorecard-action from 2.3.3 to 2.4.0
2024-07-29 15:41:37 +02:00
dependabot[bot]
161082f757
Bump ossf/scorecard-action from 2.3.3 to 2.4.0
Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action) from 2.3.3 to 2.4.0.
- [Release notes](https://github.com/ossf/scorecard-action/releases)
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md)
- [Commits](dc50aa9510...62b2cac7ed)

---
updated-dependencies:
- dependency-name: ossf/scorecard-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-29 13:33:00 +00:00
dependabot[bot]
7af241aef3
Bump github/codeql-action from 3.25.14 to 3.25.15
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.25.14 to 3.25.15.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](5cf07d8b70...afb54ba388)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-29 13:32:57 +00:00
9e18d998ba
Merge pull request #264 from wneessen/dependabot/github_actions/github/codeql-action-3.25.14
Bump github/codeql-action from 3.25.13 to 3.25.14
2024-07-25 15:39:33 +02:00
dependabot[bot]
d199a3a1e8
Bump github/codeql-action from 3.25.13 to 3.25.14
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.25.13 to 3.25.14.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](2d790406f5...5cf07d8b70)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-25 13:37:13 +00:00
07bd2d167e
Merge pull request #263 from NorbertHauriel/patch-1
fix(typo): Error text in DialAndSendWithContext
2024-07-24 13:35:33 +02:00
Norbert Hauriel
c811ee689f
fix(typo): client.go error message 2024-07-24 13:12:06 +02:00
0aecfd9b04
Merge pull request #261 from wneessen/dependabot/github_actions/github/codeql-action-3.25.13
Bump github/codeql-action from 3.25.12 to 3.25.13
2024-07-22 15:52:18 +02:00
dependabot[bot]
94fe71c647
Bump github/codeql-action from 3.25.12 to 3.25.13
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.25.12 to 3.25.13.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](4fa2a79536...2d790406f5)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-22 13:49:10 +00:00
8ea825ce1d
Merge pull request #260 from wneessen/dependabot/github_actions/step-security/harden-runner-2.9.0
Bump step-security/harden-runner from 2.8.1 to 2.9.0
2024-07-19 15:19:35 +02:00
dependabot[bot]
47e901d80d
Bump step-security/harden-runner from 2.8.1 to 2.9.0
Bumps [step-security/harden-runner](https://github.com/step-security/harden-runner) from 2.8.1 to 2.9.0.
- [Release notes](https://github.com/step-security/harden-runner/releases)
- [Commits](17d0e2bd7d...0d381219dd)

---
updated-dependencies:
- dependency-name: step-security/harden-runner
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-19 13:18:49 +00:00
0ea9631855
Refactor error handling in message delivery process
The error handling process in sending messages has been refactored for better accuracy and efficiency. Instead of immediately joining errors and returning, they are now collected in a slice and joined in a deferred function to ensure all errors are captured before being returned. Furthermore, the SendError structure has been updated to include a reference to the affected message, providing better context for each error.
2024-07-16 13:07:20 +02:00
ee3f0f1284
Merge pull request #258 from wneessen/dependabot/github_actions/actions/dependency-review-action-4.3.4
Bump actions/dependency-review-action from 4.3.3 to 4.3.4
2024-07-12 16:00:53 +02:00
b7364ae3d6
Merge pull request #259 from wneessen/dependabot/github_actions/github/codeql-action-3.25.12
Bump github/codeql-action from 3.25.11 to 3.25.12
2024-07-12 16:00:33 +02:00
dependabot[bot]
58c0f034bc
Bump github/codeql-action from 3.25.11 to 3.25.12
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.25.11 to 3.25.12.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](b611370bb5...4fa2a79536)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-12 13:59:26 +00:00
dependabot[bot]
35b3f6eba0
Bump actions/dependency-review-action from 4.3.3 to 4.3.4
Bumps [actions/dependency-review-action](https://github.com/actions/dependency-review-action) from 4.3.3 to 4.3.4.
- [Release notes](https://github.com/actions/dependency-review-action/releases)
- [Commits](72eb03d02c...5a2ce3f5b9)

---
updated-dependencies:
- dependency-name: actions/dependency-review-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-12 13:59:17 +00:00
850ea90d6b
Merge pull request #257 from wneessen/dependabot/github_actions/actions/setup-go-5.0.2
Bump actions/setup-go from 5.0.1 to 5.0.2
2024-07-11 15:43:37 +02:00
dependabot[bot]
e8b7d0825f
Bump actions/setup-go from 5.0.1 to 5.0.2
Bumps [actions/setup-go](https://github.com/actions/setup-go) from 5.0.1 to 5.0.2.
- [Release notes](https://github.com/actions/setup-go/releases)
- [Commits](cdcb360436...0a12ed9d6a)

---
updated-dependencies:
- dependency-name: actions/setup-go
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-11 13:36:12 +00:00
2cb54edc95
Merge pull request #256 from wneessen/dependabot/github_actions/actions/upload-artifact-4.3.4
Bump actions/upload-artifact from 4.3.3 to 4.3.4
2024-07-08 15:28:50 +02:00
dependabot[bot]
132fe02384
Bump actions/upload-artifact from 4.3.3 to 4.3.4
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4.3.3 to 4.3.4.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](65462800fd...0b2256b8c0)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-08 13:18:08 +00:00
e552e17a74
Merge pull request #255 from wneessen/dependabot/github_actions/fsfe/reuse-action-4.0.0
Bump fsfe/reuse-action from 3.0.0 to 4.0.0
2024-07-04 15:45:03 +02:00
dependabot[bot]
307c7de311
Bump fsfe/reuse-action from 3.0.0 to 4.0.0
Bumps [fsfe/reuse-action](https://github.com/fsfe/reuse-action) from 3.0.0 to 4.0.0.
- [Release notes](https://github.com/fsfe/reuse-action/releases)
- [Commits](a46482ca36...3ae3c6bdf1)

---
updated-dependencies:
- dependency-name: fsfe/reuse-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-04 13:42:06 +00:00
02308df4fd
Merge pull request #254 from wneessen/dependabot/github_actions/sonarsource/sonarqube-scan-action-2.3.0
Bump sonarsource/sonarqube-scan-action from 2.2.0 to 2.3.0
2024-07-02 15:53:51 +02:00
dependabot[bot]
09521758db
Bump sonarsource/sonarqube-scan-action from 2.2.0 to 2.3.0
Bumps [sonarsource/sonarqube-scan-action](https://github.com/sonarsource/sonarqube-scan-action) from 2.2.0 to 2.3.0.
- [Release notes](https://github.com/sonarsource/sonarqube-scan-action/releases)
- [Commits](540792c588...aecaf43ae5)

---
updated-dependencies:
- dependency-name: sonarsource/sonarqube-scan-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-02 13:51:17 +00:00
32a5603496
Merge pull request #253 from wneessen/feature/add_get_boundary
Add GetBoundary method and corresponding test
2024-07-02 11:11:33 +02:00
b88b67e2c7
Add GetBoundary method and corresponding test
The GetBoundary method has been added to the Msg struct in msg.go. Alongside this, a corresponding test method, TestMsg_GetBoundary, was introduced in msg_test.go to ensure the proper working of GetBoundary. This new method returns the boundary string of the Msg, which was previously inaccessible.
2024-07-02 10:58:13 +02:00
cf87ea68d3
Merge pull request #252 from wneessen/dependabot/github_actions/github/codeql-action-3.25.11
Bump github/codeql-action from 3.25.10 to 3.25.11
2024-07-01 23:13:35 +02:00
dependabot[bot]
ca0d94c7a7
Bump github/codeql-action from 3.25.10 to 3.25.11
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.25.10 to 3.25.11.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](23acc5c183...b611370bb5)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-01 13:44:21 +00:00
ffdea8337e
Merge pull request #249 from wneessen/feature/145_add-eml-parser-to-generate-msg-from-eml-files
This PR introduces an EML parser to go-mail. It allows to read generic EML data from a file, a string or a reader into a go-mail Msg struct. It supports all types of message parts and encodings. It should be able to recognize Mulitpart messages as well as attachments and embeds (inline attachments).

This PR closes #145
2024-06-28 14:11:30 +02:00
7e4bb00538
Add error handling for writing EML string to temp file
Added conditional statements to handle potential failures when writing the EML string to the temporary files during testing. These updates ensure test failures due to write errors are accurately reflected in test results. Also, a minor fix is implemented on file permission in the os.WriteFile function.
2024-06-28 13:59:08 +02:00
d9290973be
Bump version to 0.4.2 2024-06-28 13:53:00 +02:00
2fa52e5341
Add EML file support to go-mail in README
The README has been updated to show that go-mail now supports outputting a message as an EML file and parsing an EML file into a go-mail message. This addition enhances the flexibility and control over the email content and format.
2024-06-28 13:51:49 +02:00
8924e426d6
Add test for WithFileContentID option
The change introduces a new unit test, TestFile_WithContentID, in file_test.go. This test aims to verify the correct function of the WithFileContentID option by using differing scenarios, with assertions for error control and validation of expected content.
2024-06-28 13:49:34 +02:00
4e7082a540
Rename WithContentID to WithFileContentID
In the eml.go and file.go files, the function WithContentID has been renamed to WithFileContentID. This aligns more accurately with the function purpose, which is to set the content ID for a File object.
2024-06-28 13:49:21 +02:00
ca201b1548
Add tests for various email scenarios
This commit introduces tests for different email scenarios including emails with no boundaries, emails with attachments, emails with embedded items, and multipart mixed emails. The tests ensure that the code correctly returns all expected parts of the email (e.g., embeds, attachments, parts) and that it correctly processes the email subject.
2024-06-28 13:45:22 +02:00