- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我从事用户密码安全方面的工作,对我来说最重要的事情之一是当在最常见的密码列表中找到密码时强制用户重新输入密码。
执行此操作的最佳方法是什么?
最佳答案
我想到了这个方法,它工作正常。它检测 500 个最常见的密码。如果密码字段中有列入黑名单的密码条目,则返回 'true'。
希望对大家有帮助。
function passwordPreventCommon(commonValue) {
var commonPassword = Array("123456","password","12345678","1234","pussy","12345","dragon","qwerty","696969","mustang","letmein","baseball","master","michael","football","shadow","monkey","abc123","pass","6969","jordan","harley","ranger","iwantu","jennifer","hunter","2000","test","batman","trustno1","thomas","tigger","robert","access","love","buster","1234567","soccer","hockey","killer","george","sexy","andrew","charlie","superman","asshole","dallas","jessica","panties","pepper","1111","austin","william","daniel","golfer","summer","heather","hammer","yankees","joshua","maggie","biteme","enter","ashley","thunder","cowboy","silver","richard","orange","merlin","michelle","corvette","bigdog","cheese","matthew","121212","patrick","martin","freedom","ginger","blowjob","nicole","sparky","yellow","camaro","secret","dick","falcon","taylor","111111","131313","123123","bitch","hello","scooter","please","","porsche","guitar","chelsea","black","diamond","nascar","jackson","cameron","654321","computer","amanda","wizard","xxxxxxxx","money","phoenix","mickey","bailey","knight","iceman","tigers","purple","andrea","horny","dakota","aaaaaa","player","sunshine","morgan","starwars","boomer","cowboys","edward","charles","girls","booboo","coffee","xxxxxx","bulldog","ncc1701","rabbit","peanut","john","johnny","gandalf","spanky","winter","brandy","compaq","carlos","tennis","james","mike","brandon","fender","anthony","blowme","ferrari","cookie","chicken","maverick","chicago","joseph","diablo","sexsex","hardcore","666666","willie","welcome","chris","panther","yamaha","justin","banana","driver","marine","angels","fishing","david","maddog","hooters","wilson","butthead","dennis","captain","bigdick","chester","smokey","xavier","steven","viking","snoopy","blue","eagles","winner","samantha","house","miller","flower","jack","firebird","butter","united","turtle","steelers","tiffany","zxcvbn","tomcat","golf","bond007","bear","tiger","doctor","gateway","gators","angel","junior","thx1138","porno","badboy","debbie","spider","melissa","booger","1212","flyers","fish","porn","matrix","teens","scooby","jason","walter","cumshot","boston","braves","yankee","lover","barney","victor","tucker","princess","mercedes","5150","doggie","zzzzzz","gunner","horney","bubba","2112","fred","johnson","xxxxx","tits","member","boobs","donald","bigdaddy","bronco","penis","voyager","rangers","birdie","trouble","white","topgun","bigtits","bitches","green","super","qazwsx","magic","lakers","rachel","slayer","scott","2222","asdf","video","london","7777","marlboro","srinivas","internet","action","carter","jasper","monster","teresa","jeremy","11111111","bill","crystal","peter","pussies","cock","beer","rocket","theman","oliver","prince","beach","amateur","7777777","muffin","redsox","star","testing","shannon","murphy","frank","hannah","dave","eagle1","11111","mother","nathan","raiders","steve","forever","angela","viper","ou812","jake","lovers","suckit","gregory","buddy","whatever","young","nicholas","lucky","helpme","jackie","monica","midnight","college","baby","brian","mark","startrek","sierra","leather","232323","4444","beavis","bigcock","happy","sophie","ladies","naughty","giants","booty","blonde","golden","0","fire","sandra","pookie","packers","einstein","dolphins","0","chevy","winston","warrior","sammy","slut","8675309","zxcvbnm","nipples","power","victoria","asdfgh","vagina","toyota","travis","hotdog","paris","rock","xxxx","extreme","redskins","erotic","dirty","ford","freddy","arsenal","access14","wolf","nipple","iloveyou","alex","florida","eric","legend","movie","success","rosebud","jaguar","great","cool","cooper","1313","scorpio","mountain","madison","987654","brazil","lauren","japan","naked","squirt","stars","apple","alexis","aaaa","bonnie","peaches","jasmine","kevin","matt","qwertyui","danielle","beaver","4321","4128","runner","swimming","dolphin","gordon","casper","stupid","shit","saturn","gemini","apples","august","3333","canada","blazer","cumming","hunting","kitty","rainbow","112233","arthur","cream","calvin","shaved","surfer","samson","kelly","paul","mine","king","racing","5555","eagle","hentai","newyork","little","redwings","smith","sticky","cocacola","animal","broncos","private","skippy","marvin","blondes","enjoy","girl","apollo","parker","qwert","time","sydney","women","voodoo","magnum","juice","abgrtyu","777777","dreams","maxwell","music","rush2112","russia","scorpion","rebecca","tester","mistress","phantom","billy","6666","albert");
for (var i=0; i < commonPassword.length; i++) {
if (commonPassword[i]===commonValue) {
return true;
}
};
return false;
};
在将它包含在某个地方之前用简单的警报测试它:
alert(passwordPreventCommon('password'));
当“密码”一词被列入黑名单时,它将警告“真”。
编辑: 迭代部分可以用 ES6 中的 includes() 方法替换:
if (commonPassword.includes(commonValue)) {
return true;
}
关于javascript - 检测常用密码并防止用户设置的功能?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11780249/
本文主要给大家介绍Mysql数据库分库和分表方式(常用),涉及到mysql数据库相关知识,对mysql数据库分库分表相关知识感兴趣的朋友一起学习吧 1 分库 1.1 按照功能分库 按照功能进行
在当前对象由其他包含对象操作的系统中,当传递对当前对象的引用时,链接似乎一直在继续......没有任何结束(对于下面的代码,Car ->myCurrentComponent->myCar_Brake-
我有一个密码 UIAlertView,我们要求用户提供。我需要根据情况在不同的 View 上询问它,从 downloadViewController (用户下载数据后),当他们切换到他们的数据时(如果
我正在尝试编写一个函数,使得对于任何整数 x 的 P(x) 都有一个包含三个元素的列表,即平方、立方和 n 的四次方,但我仍然不知道如何组合然后制作一个函数,例如我有平方、立方体和 4 次幂函数下面是
关闭。这个问题需要更多 focused .它目前不接受答案。 关闭4年前。 锁定。这个问题及其答案是locked因为这个问题是题外话,但具有历史意义。它目前不接受新的答案或交互。 我能否列出一份常见的
Python 常用 PEP8 编码规范 代码布局 缩进 每级缩进用4个空格。 括号中使用垂直隐式缩进或使用悬挂缩进。 EXAMPLE: ?
关闭。这个问题需要更多focused .它目前不接受答案。 想改善这个问题吗?更新问题,使其仅关注一个问题 editing this post . 去年关闭。 Improve this questio
在经典 ui 中,您可以使用 xtype:cqinclude 包含来自不同路径的 rtePlugins,基本上为标准 RTE 插件创建一个位置,我如何在 Touch UI 中执行相同操作? 我尝试使用
在经典 ui 中,您可以使用 xtype:cqinclude 包含来自不同路径的 rtePlugins,基本上为标准 RTE 插件创建一个位置,我如何在 Touch UI 中执行相同操作? 我尝试使用
*strong text*我有多个网络应用程序使用了一些常见的依赖项,比如蒙戈连接器谷歌 Guava 乔达时间 我想到将它们从 webapp/WEB-INF/lib 中取出并放入一些 common-l
我正在编写一个 Web 服务器,我想知道哪些 HTTP 请求 header (由客户端发送)是最常见的,因此我应该重点实现。 目前,我只支持Accept 和Host。 最佳答案 不确定您的范围,但由于
我是一名优秀的程序员,十分优秀!