PHPMailer隐藏SMTP身份验证?

编程入门 行业动态 更新时间:2024-10-09 14:26:08
本文介绍了PHPMailer隐藏SMTP身份验证?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

好,我正在使用PHPMailer发送电子邮件.

Ok, I'm using PHPMailer to send email.

因此,在php代码中,我添加了我的SMTP用户名,即我的gmail帐户 和SMTP密码,这是我的gmail帐户密码.

So in the php code I add my SMTP username, which is my gmail account and the SMTP password, which is my gmail account password.

所以我的GMAIL帐户访问权限已暴露在php代码中,尽管该服务器 在解释后将其丢弃,因此没人能看到它,我的问题 是,这可靠吗? 我应该在代码中保留gmail访问权限还是应该将其保存在数据库中?

So my GMAIL ACCOUNT ACCESS is EXPOSED in php CODE, although the server discards the php after it's been interpreted so nobody can see it, my question is, is this reliable? Should I leave my gmail access in the code or should I save it in my database?

预先感谢

推荐答案

任何有权访问您代码的开发人员都可以访问您的凭据.将这些信息保存在数据库中可能会使访问细节变得有些困难,但只是略微困难.

Any developer with access to your code will be able to access your credentials. Saving these in a database may make it a little tougher to gain access to the details, but only slightly.

如果您真的担心所使用的凭据,请创建一个专用于您的网站的帐户,不要使用个人帐户.

If you are truly concerned about the credentials used, create an account dedicated to your site and do not use a personal account.

更多推荐

PHPMailer隐藏SMTP身份验证?

本文发布于:2023-05-31 14:01:02,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/393037.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:身份验证   PHPMailer   SMTP

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!