diff options
author | Denis Vlasenko | 2007-05-08 17:52:17 +0000 |
---|---|---|
committer | Denis Vlasenko | 2007-05-08 17:52:17 +0000 |
commit | 7e84e539de530b2060f0e570fc8f063ed0aaad2f (patch) | |
tree | c03518f2059504a513119cf4d499ccf5c7233f83 /include | |
parent | 92c0b8222eb50dd35c06e2f1265706b388762234 (diff) | |
download | busybox-7e84e539de530b2060f0e570fc8f063ed0aaad2f.zip busybox-7e84e539de530b2060f0e570fc8f063ed0aaad2f.tar.gz |
cryptpw: new applet (a bit less than 3k added)
(by Thomas Lundquist <lists@zelow.no>)
Diffstat (limited to 'include')
-rw-r--r-- | include/applets.h | 1 | ||||
-rw-r--r-- | include/libbb.h | 2 | ||||
-rw-r--r-- | include/usage.h | 7 |
3 files changed, 10 insertions, 0 deletions
diff --git a/include/applets.h b/include/applets.h index 67f7db4..a7aee3a 100644 --- a/include/applets.h +++ b/include/applets.h @@ -101,6 +101,7 @@ USE_CP(APPLET_NOEXEC(cp, cp, _BB_DIR_BIN, _BB_SUID_NEVER, cp)) USE_CPIO(APPLET(cpio, _BB_DIR_BIN, _BB_SUID_NEVER)) USE_CROND(APPLET(crond, _BB_DIR_USR_SBIN, _BB_SUID_NEVER)) USE_CRONTAB(APPLET(crontab, _BB_DIR_USR_BIN, _BB_SUID_ALWAYS)) +USE_CRYPTPW(APPLET(cryptpw, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) USE_CUT(APPLET_NOEXEC(cut, cut, _BB_DIR_USR_BIN, _BB_SUID_NEVER, cut)) USE_DATE(APPLET(date, _BB_DIR_BIN, _BB_SUID_NEVER)) USE_DC(APPLET(dc, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) diff --git a/include/libbb.h b/include/libbb.h index be51f25..32bb311 100644 --- a/include/libbb.h +++ b/include/libbb.h @@ -718,6 +718,7 @@ extern int bb_parse_mode(const char* s, mode_t* theMode); char *concat_path_file(const char *path, const char *filename); char *concat_subpath_file(const char *path, const char *filename); +/* NB: can violate const-ness (similarly to strchr) */ char *last_char_is(const char *s, int c); @@ -755,6 +756,7 @@ extern int index_in_substr_array(const char * const string_array[], const char * extern void print_login_issue(const char *issue_file, const char *tty); extern void print_login_prompt(void); +extern void crypt_make_salt(char *p, int cnt); int get_terminal_width_height(const int fd, int *width, int *height); diff --git a/include/usage.h b/include/usage.h index afcc4b3..eab9601 100644 --- a/include/usage.h +++ b/include/usage.h @@ -474,6 +474,13 @@ " -d [user] delete crontab for user\n" \ " -c dir specify crontab directory" +#define cryptpw_trivial_usage \ + "[-a des|md5] [string]" +#define cryptpw_full_usage \ + "Outputs crypted string.\n" \ + "If string isn't supplied on cmdline, reads it from stdin.\n" \ + "\nOptions:" \ + "\n -a Algorithm to use (default: md5)" #define cut_trivial_usage \ "[OPTION]... [FILE]..." |