mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-02 04:13:39 +00:00
API cleanups (use const char * where appropriate)
Cannidate for: 2.2 (please!)
This commit is contained in:
parent
eb2c768ebb
commit
1a277b7ae9
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=23503
@ -49,12 +49,12 @@ void rip __P((char *buf));
|
||||
|
||||
/* Simplified application programming interface. */
|
||||
#include <pwd.h>
|
||||
int skeylookup __P((struct skey *mp,char *name));
|
||||
int skeyverify __P((struct skey *mp,char *response));
|
||||
int skeychallenge __P((struct skey *mp,char *name, char *challenge));
|
||||
int skeyinfo __P((struct skey *mp, char* name, char *ss));
|
||||
int skeyaccess __P((char *user, char *port, char *host, char *addr));
|
||||
char *skey_getpass __P((char *prompt, struct passwd *pwd, int pwok));
|
||||
int skeylookup __P((struct skey *mp, const char *name));
|
||||
int skeyverify __P((struct skey *mp, char *response));
|
||||
int skeychallenge __P((struct skey *mp, const char *name, char *challenge));
|
||||
int skeyinfo __P((struct skey *mp, const char* name, char *ss));
|
||||
int skeyaccess __P((char *user, const char *port, const char *host, const char *addr));
|
||||
char *skey_getpass __P((const char *prompt, struct passwd * pwd, int pwok));
|
||||
char *skey_crypt __P((char *pp, char *salt, struct passwd *pwd, int pwok));
|
||||
|
||||
#endif /* _SKEY_H_ */
|
||||
|
@ -8,9 +8,9 @@
|
||||
|
||||
/* skey_crypt - return encrypted UNIX passwd if s/key or regular password ok */
|
||||
|
||||
char *skey_crypt(pp, salt, pwd, pwok)
|
||||
char *pp;
|
||||
char *salt;
|
||||
char *skey_crypt(pp, salt, pwd, pwok)
|
||||
char *pp;
|
||||
char *salt;
|
||||
struct passwd *pwd;
|
||||
int pwok;
|
||||
{
|
||||
|
@ -4,8 +4,8 @@
|
||||
|
||||
/* skey_getpass - read regular or s/key password */
|
||||
|
||||
char *skey_getpass(prompt, pwd, pwok)
|
||||
char *prompt;
|
||||
char *skey_getpass(prompt, pwd, pwok)
|
||||
const char *prompt;
|
||||
struct passwd *pwd;
|
||||
int pwok;
|
||||
{
|
||||
|
@ -41,7 +41,7 @@ static char *month[12] = {
|
||||
int
|
||||
skeyinfo(mp,name,ss)
|
||||
struct skey *mp;
|
||||
char *name;
|
||||
const char *name;
|
||||
char *ss;
|
||||
{
|
||||
int rval;
|
||||
@ -73,7 +73,7 @@ char *ss;
|
||||
int
|
||||
skeychallenge(mp,name, ss)
|
||||
struct skey *mp;
|
||||
char *name;
|
||||
const char *name;
|
||||
char *ss;
|
||||
{
|
||||
int rval;
|
||||
@ -101,7 +101,7 @@ char *ss;
|
||||
int
|
||||
skeylookup(mp,name)
|
||||
struct skey *mp;
|
||||
char *name;
|
||||
const char *name;
|
||||
{
|
||||
int found;
|
||||
int len;
|
||||
@ -191,7 +191,7 @@ char *response;
|
||||
tm = localtime(&now);
|
||||
/* can't use %b here, because it can be in national form */
|
||||
strftime(fbuf, sizeof(fbuf), "%d,%Y %T", tm);
|
||||
sprintf(tbuf, " %s %s", month[tm->tm_mon], fbuf);
|
||||
snprintf(tbuf, sizeof(tbuf), " %s %s", month[tm->tm_mon], fbuf);
|
||||
|
||||
if(response == NULL){
|
||||
fclose(mp->keyfile);
|
||||
|
Loading…
Reference in New Issue
Block a user