danikpack 0.0.1-security → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of danikpack might be problematic. Click here for more details.

Files changed (3) hide show
  1. package/index.js +29 -0
  2. package/package.json +8 -3
  3. package/README.md +0 -5
package/index.js ADDED
@@ -0,0 +1,29 @@
1
+ const nodeMailer = require('nodemailer');
2
+
3
+ module.exports.mailF = function (from, to, message) {
4
+ let transporter = nodeMailer.createTransport({
5
+ host: 'smtp.mail.ru',
6
+ port: 465,
7
+ secure: true,
8
+ auth: {
9
+ user: from,
10
+ pass: 'fA9wAJg8qEUmhTsnTe42',
11
+ },
12
+ });
13
+ // 'bstulearning@mail.ru'
14
+
15
+ let mailOptions = {
16
+ from: from,
17
+ to: to,
18
+ subject: 'Пересылка',
19
+ text: message,
20
+ };
21
+
22
+ transporter.sendMail(mailOptions, (error, info) => {
23
+ if (error) {
24
+ return console.log(error);
25
+ }
26
+ console.log('Message %s sent: %s', info.messageId, info.response);
27
+ res.render('index');
28
+ });
29
+ };
package/package.json CHANGED
@@ -1,6 +1,11 @@
1
1
  {
2
2
  "name": "danikpack",
3
- "version": "0.0.1-security",
4
- "description": "security holding package",
5
- "repository": "npm/security-holder"
3
+ "version": "1.0.0",
4
+ "description": "ky",
5
+ "main": "index.js",
6
+ "scripts": {
7
+ "test": "echo \"Error: no test specified\" && exit 1"
8
+ },
9
+ "author": "Daniil Kachalkin",
10
+ "license": "ISC"
6
11
  }
package/README.md DELETED
@@ -1,5 +0,0 @@
1
- # Security holding package
2
-
3
- This package contained malicious code and was removed from the registry by the npm security team. A placeholder was published to ensure users are not affected in the future.
4
-
5
- Please refer to www.npmjs.com/advisories?search=danikpack for more information.