CodeIgniter Forums
Remove User-Agent Header - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forum-5.html)
+--- Forum: General Help (https://forum.codeigniter.com/forum-24.html)
+--- Thread: Remove User-Agent Header (/thread-67521.html)



Remove User-Agent Header - edica - 03-04-2017

Hello.

For Security reasons. How to remove these two information in the received mail header:

User-Agent: CodeIgniter
X-Mailer: CodeIgniter


Thanks for helping.


RE: Remove User-Agent Header - lisheng51 - 03-04-2017

system/libraries/Email.php

public $useragent = 'CodeIgniter';


RE: Remove User-Agent Header - Paradinight - 03-05-2017

(03-04-2017, 12:21 PM)lisheng51 Wrote: system/libraries/Email.php

public $useragent = 'CodeIgniter';

Do not change the Email.php in the system folder

https://www.codeigniter.com/user_guide/libraries/email.html#email-preferences

$config['useragent'] = 'NewAgent';


RE: Remove User-Agent Header - edica - 03-06-2017

(03-05-2017, 02:43 AM)Paradinight Wrote:
(03-04-2017, 12:21 PM)lisheng51 Wrote: system/libraries/Email.php

public $useragent = 'CodeIgniter';

Do not change the Email.php in the system folder

https://www.codeigniter.com/user_guide/libraries/email.html#email-preferences

$config['useragent'] = 'NewAgent';

Excellent. Thank you so much.