Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
O
osticket
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
docker
osticket
Commits
f16830d1
Unverified
Commit
f16830d1
authored
5 years ago
by
Peter Rotich
Committed by
GitHub
5 years ago
Browse files
Options
Downloads
Plain Diff
Merge pull request #4894 from aydreeihn/issue/incorrect-reply-to
Reformat Incorrect Reply-To Headers
parents
40ad7c2a
e9dda94a
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
include/class.mailfetch.php
+12
-0
12 additions, 0 deletions
include/class.mailfetch.php
with
12 additions
and
0 deletions
include/class.mailfetch.php
+
12
−
0
View file @
f16830d1
...
...
@@ -671,6 +671,18 @@ class MailFetcher {
// attachment. Download the body and pass it along to the mail
// parsing engine.
$info
=
Mail_Parse
::
splitHeaders
(
$mailinfo
[
'header'
]);
//make sure reply-to headers are correctly formatted
if
(
$mailinfo
[
'reply-to'
]
&&
!
Validator
::
is_email
(
$mailinfo
[
'reply-to'
])
&&
$info
[
'Reply-To'
])
{
$replyto
=
Mail_Parse
::
parseAddressList
(
$info
[
'Reply-To'
]);
if
(
$replyto
[
0
])
{
$mailinfo
[
'reply-to'
]
=
sprintf
(
'%s@%s'
,
$replyto
[
0
]
->
mailbox
,
$replyto
[
0
]
->
host
);
$mailinfo
[
'reply-to-name'
]
=
$replyto
[
0
]
->
personal
;
}
else
{
$mailinfo
[
'reply-to'
]
=
null
;
}
}
if
(
strtolower
(
$info
[
'Content-Type'
])
==
'message/rfc822'
)
{
if
(
$wrapped
=
$this
->
getPart
(
$mid
,
'message/rfc822'
))
{
require_once
INCLUDE_DIR
.
'api.tickets.php'
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment