{"bugs":{"url":"https://github.com/Jackthomsonn/X-Auth/issues"},"dist":{"shasum":"a74a7ec47641451c64e0d645b6aee21c21817282","tarball":"https://registry.npmjs.org/x-auth-plugin/-/x-auth-plugin-0.0.4-beta.tgz","fileCount":22,"integrity":"sha512-+WYTXz8WHOeI9GypfGWdQGVCmi4xXUmnJT16HLx3UVH286TjQf8dEtKC7nv8ri17Lu3WXrY89MCw1g8UIjAXfg==","signatures":[{"sig":"MEYCIQCtAjOcIsZ71iWD0fTMKxIrGjDVzOF3NNcx8CHqsVbv8AIhALfP5q0MdO3TEVR/OktSn4BiokNdv0+0nnBQ3wbAZ6TZ","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":100964,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbHQBYCRA9TVsSAnZWagAAR5MP/1f+pphuxIStPc9fblNw\nPKbLCZ9Thb5Ufn8JfhmQ5NBex/5LV5bvsFe/w6tUsb1SX7lbuBZBUzP5IC6v\nkxMOVQp66xyB3WlDomotQF/JWiK4HIOrFOqnEeM7MUzWJ7jrSJ3YHrqW/oIf\nhkRs8H2/SRlzLgNqF8q6PLz9LeidpXCSDg5R7NoA8RcWm+ZUWRGd/uZpoeXl\nQDu2f37beqJQeCsY70oHLQrFBYIU7WbNmwUFyOymXbqFY2QAVtDGr+R70jra\nO+CEqIlQy13Qg2avkgX5wO5fohZ0YnrrS6gEKBmZevOsFKLwgByGKm+VQmLj\nGuSUry6GTljDLUdL6UEtCyEtSeanIw5FMqEWQ7lHv2zRZ9czIIcxraSjMlta\nx84fvDQMrqWgzTWTmbKtfkO+iE1v5C75Jn51Cppq0rZIY07Ub4VgU7QK5Wkj\nC5T2vc/YZLwUc2/op6vMKxVNbw6KDdpyZ1Ybwok6KeFWgdQWwRMn2TkLlCAN\nzw1mjqm93buEjTFWgeo/DS0ZJf2myTfXHIHyYM3vPs3K8EqdmFgksaikdics\ncSJFOOucirLMKhvcHXt0BqCkYP+MOwORiyuLJyRMLn4Tz77iCz6PbvH9viX0\n5JfTcmN5mKsWZyJMUSvVtOaDWIQbC90K2yIiJ3pBD7Fe34+URBSg6hyQKghT\nzdwF\r\n=+rrV\r\n-----END PGP SIGNATURE-----\r\n"},"main":"x-auth.js","name":"x-auth-plugin","author":{"name":"Jack Thomson"},"readme":"# X-Auth\n\nX-Auth is a plugin built for the Dynamic Route Generator that gives you a fully fledged login system for your web applications. This is a plug and play plugin with a few lines of configuration setup.\n\n#### Features\n- Login\n- Register\n- Two Factor Login\n- Forgot Password\n- Change Password\n- Email verifications\n- SMS Integration for two factor authentication (Optional, will need to pay; current client configured is Text Magic)\n\nThis plugin is in beta and **SHOULD NOT** be used in a production environment as of yet. There is a lot of work and testing that needs to be carried out to prove this system is secure\n\n#### Example Setup\n\n```\nconst app = require('express')()\nconst mongoose = require('mongoose')\n\nconst RouteGenerator = require('dynamic-route-generator')\n\nconst { XAuth, CheckAuthentication } = require('x-auth')\n\nconst GameModel = require('./game.model')\n\nmongoose.connect('mongodb://localhost/test')\n\nXAuth.setupProps({\n  appName: 'XAuth Test',\n  authSecretKey: '12345',\n  authSecretKeyForgottenPassword: '12345',\n  cookieName: 'xauth-test',\n  cookieNameForgottenPassword: 'xauth-forgotten-password-test',\n  domainEmail: 'hello@email.com',\n  jwtTokenExpiration: 300000, // 5 minutes (Applied to cookie expiration also)\n  saltWorkFactor: 10,\n  databaseUri: 'mongodb://localhost/test',\n  themeColour: '#4096EE',\n  emailVerification: true\n})\n\nnew RouteGenerator({\n  routes: [{\n    uri: '/list/games',\n    model: GameModel,\n    handlers: [CheckAuthentication],\n    methods: [{\n      name: 'get'\n    }]\n  }],\n  app,\n  plugins: {\n    pre: [XAuth]\n    post: []\n  }\n})\n\napp.listen(process.env.PORT || 8080)\n```\n","gitHead":"0185a773cf0bd252dba2e08c865495f272b08fe1","license":"ISC","scripts":{"publish-npm:beta":"npm publish --tag=next"},"_npmUser":{"name":"jackthomsonn","email":"hello@jackthomson.co.uk"},"homepage":"https://github.com/Jackthomsonn/X-Auth#readme","keywords":["dynamic","route","generator","authentication","plug","and","play","X Auth"],"repository":{"url":"git+https://github.com/Jackthomsonn/X-Auth.git","type":"git"},"_npmVersion":"6.0.1","description":"X-Auth is a plugin built for the Dynamic Route Generator that gives you a fully fledged login system for your web applications","directories":{},"maintainers":[{"name":"jackthomsonn","email":"hello@jackthomson.co.uk"}],"_nodeVersion":"8.11.2","dependencies":{"ms":"2.1.1","moment":"^2.22.1","express":"4.16.2","request":"^2.85.0","bcryptjs":"2.4.3","mongoose":"5.0.8","sendmail":"1.4.1","jsonwebtoken":"8.2.0","awesome-phonenumber":"^2.2.5","textmagic-rest-client":"^1.0.10","dynamic-route-generator":"1.1.0"},"_hasShrinkwrap":false,"readmeFilename":"README.md","_npmOperationalInternal":{"tmp":"tmp/x-auth-plugin_0.0.4-beta_1528627288097_0.25715124566321523","host":"s3://npm-registry-packages"},"_id":"x-auth-plugin@0.0.4-beta","version":"0.0.4-beta"}