From e2e299ada2f985ab99a7cc17c4c12d3e16123fb5 Mon Sep 17 00:00:00 2001 From: Alex Kern Date: Wed, 6 May 2015 15:39:33 -0700 Subject: [PATCH] Use pizza toppings for tokens. --- lib/db.js | 4 +- lib/toppings.js | 98 +++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 101 insertions(+), 1 deletion(-) create mode 100644 lib/toppings.js diff --git a/lib/db.js b/lib/db.js index d31fc2e..6429096 100644 --- a/lib/db.js +++ b/lib/db.js @@ -1,3 +1,4 @@ +import toppings from './toppings' import xkcdPassword from 'xkcd-password' const TOKEN_OPTIONS = { @@ -6,8 +7,9 @@ const TOKEN_OPTIONS = { maxLength: 8 } -var tokenGenerator = new xkcdPassword() var tokens = {} +var tokenGenerator = new xkcdPassword() +tokenGenerator.initWithWordList(toppings) export function create(socket) { diff --git a/lib/toppings.js b/lib/toppings.js new file mode 100644 index 0000000..257a88f --- /dev/null +++ b/lib/toppings.js @@ -0,0 +1,98 @@ +export default [ + "alfalfa", + "almonds", + "anchovies", + "artichoke", + "avocado", + "bacon", + "basil", + "bayleaf", + "bbqchicken", + "beans", + "beef", + "beetroot", + "bluecheese", + "brie", + "broccoli", + "cajunchicken", + "camembert", + "capers", + "capicolla", + "cardamon", + "carrot", + "cauliflower", + "chedar", + "chickenmasala", + "chickentikka", + "chili", + "chives", + "chorizo", + "cilantro", + "colby", + "coriander", + "crayfish", + "cumin", + "dill", + "duck", + "eggplant", + "fenugreek", + "feta", + "fungi", + "garlic", + "goatcheese", + "gorgonzola", + "gouda", + "ham", + "jalapeno", + "laurel", + "leeks", + "lettuce", + "limburger", + "lobster", + "manchego", + "marjoram", + "meatballs", + "montereyjack", + "mozzarella", + "muenster", + "mushrooms", + "olives", + "onions", + "oregano", + "oysters", + "parley", + "parmesan", + "peanuts", + "peas", + "pecans", + "pepperoni", + "peppers", + "pinenuts", + "pistachios", + "prawn", + "proscuitto", + "provolone", + "ricota", + "romano", + "roquefort", + "rosemary", + "salami", + "salmon", + "sausage", + "scallions", + "shallots", + "shrimps", + "snowpeas", + "spinach", + "squash", + "squid", + "sweetcorn", + "tomatoes", + "tuna", + "turkey", + "venison", + "walnuts", + "watercress", + "whitebait", + "zucchini" +]