/** * upwgen generates random internationalized passwords * Copyright (C) 2019 Aaron Ball <nullspoon@oper.io> * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. */ #include <stdlib.h> #include "i18n_cat.h" #define I18N_SETSIZE 1024 #define I18N_TYPE_ASCII_LOWER 1000 #define I18N_TYPE_ASCII_UPPER 1100 #define I18N_TYPE_ASCII_NUMERALS 1200 #define I18N_TYPE_ASCII_SYMBOLS 1300 #define I18N_TYPE_ONE 2000 #define I18N_TYPE_TWO 3000 #define I18N_TYPE_THREE 4000 #define I18N_TYPE_FOUR 5000 struct i18n_set { int type; int count; unsigned int chars[I18N_SETSIZE]; struct i18n_set* next; }; struct i18n_set* i18n_set_new(int); struct i18n_set* i18n_set_add(struct i18n_set*, int); struct i18n_set* i18n_set_exists(struct i18n_set*, int); struct i18n_set* i18n_set_rm_type(struct i18n_set*, int); void i18n_set_dump(struct i18n_set*); void i18n_set_free(struct i18n_set*);