| OLD | NEW |
| 1 /* | 1 /* |
| 2 ** Copyright (c) 1999, 2000, 2001, 2002, 2003 | 2 ** Copyright (c) 1999, 2000, 2001, 2002, 2003 |
| 3 ** Adel I. Mirzazhanov. All rights reserved | 3 ** Adel I. Mirzazhanov. All rights reserved |
| 4 ** | 4 ** |
| 5 ** Redistribution and use in source and binary forms, with or without | 5 ** Redistribution and use in source and binary forms, with or without |
| 6 ** modification, are permitted provided that the following conditions | 6 ** modification, are permitted provided that the following conditions |
| 7 ** are met: | 7 ** are met: |
| 8 ** | 8 ** |
| 9 ** 1.Redistributions of source code must retain the above copyright notice, | 9 ** 1.Redistributions of source code must retain the above copyright notice, |
| 10 ** this list of conditions and the following disclaimer. | 10 ** this list of conditions and the following disclaimer. |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 ** NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS | 26 ** NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
| 27 ** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 27 ** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 28 */ | 28 */ |
| 29 | 29 |
| 30 /* | 30 /* |
| 31 ** randpass.h | 31 ** randpass.h |
| 32 */ | 32 */ |
| 33 #ifndef APG_RANDPASS_H | 33 #ifndef APG_RANDPASS_H |
| 34 #define APG_RANDPASS_H 1 | 34 #define APG_RANDPASS_H 1 |
| 35 | 35 |
| 36 #ifndef APG_RND_H | |
| 37 #include "rnd.h" | |
| 38 #endif | |
| 39 | |
| 40 #ifndef APG_OWN_TYPES_H | 36 #ifndef APG_OWN_TYPES_H |
| 41 #include "owntypes.h" | 37 #include "owntypes.h" |
| 42 #endif | 38 #endif |
| 43 | 39 |
| 44 #define S_NB 0x01 /* Numeric */ | |
| 45 #define S_SS 0x02 /* Special */ | |
| 46 #define S_CL 0x04 /* Capital */ | |
| 47 #define S_SL 0x08 /* Small */ | |
| 48 #define S_RS 0x10 /* Restricted Symbol*/ | |
| 49 | |
| 50 struct sym | 40 struct sym |
| 51 { | 41 { |
| 52 char ch; | 42 char ch; |
| 53 USHORT type; | 43 USHORT type; |
| 54 }; | 44 }; |
| 55 | 45 |
| 56 /* char gen_symbol(unsigned short int symbol_class); */ | 46 /* char gen_symbol(unsigned short int symbol_class); */ |
| 57 extern int gen_rand_pass(char* password_string, int minl, | 47 extern int gen_rand_pass(char* password_string, int minl, |
| 58 int maxl, unsigned int pass_mode); | 48 int maxl, unsigned int pass_mode); |
| 59 extern int gen_rand_symbol (char *symbol, unsigned int mode); | 49 extern int gen_rand_symbol (char *symbol, unsigned int mode); |
| 60 extern int is_restricted_symbol (char symbol); | 50 extern int is_restricted_symbol (char symbol); |
| 61 | 51 |
| 62 #endif /* RANDPASS_H */ | 52 #endif /* RANDPASS_H */ |
| OLD | NEW |