to mk_error do. */
krberror.error = ret;
krberror.error -= ERROR_TABLE_BASE_krb5;
- if (krberror.error < 0 || krberror.error > KRB_ERR_MAX)
+ if (krberror.error > KRB_ERR_MAX)
krberror.error = KRB_ERR_GENERIC;
krberror.client = NULL;
/* Test a DES implementation against known inputs & outputs. */
#include "des_int.h"
+#include <ctype.h>
#include <stdio.h>
void convert (char *, unsigned char []);
{
register int i;
for (i = 0; i < 8; i++) {
- if (text[i*2] < 0 || text[i*2] >= 128)
+ if (!isascii((unsigned char)text[i * 2]))
abort ();
if (value[(int) text[i*2]] == -1 || value[(int) text[i*2+1]] == -1) {
printf("Bad value byte %d in %s\n", i, text);
static void
set_from_utf8str(krb5_data *d, utf8str_t u)
{
- if (u.utf8str_t_len > INT_MAX-1 || u.utf8str_t_len >= SIZE_MAX-1) {
+ if (u.utf8str_t_len > INT_MAX - 1) {
d->data = NULL;
return;
}
break;
case AT_FAIL_AUTH_COUNT:
- if (!exclude_nra && entry->fail_auth_count >= (krb5_kvno)0) {
+ if (!exclude_nra) {
ULOG_ENTRY_TYPE(update, ++final).av_type =
AT_FAIL_AUTH_COUNT;
ULOG_ENTRY(update, final).av_fail_auth_count =
if (err)
return NULL;
- assert(keynum >= 0 && keynum < K5_KEY_MAX);
assert(destructors_set[keynum] == 1);
#ifndef ENABLE_THREADS
if (err)
return err;
- assert(keynum >= 0 && keynum < K5_KEY_MAX);
assert(destructors_set[keynum] == 1);
#ifndef ENABLE_THREADS
if (err)
return err;
- assert(keynum >= 0 && keynum < K5_KEY_MAX);
-
#ifndef ENABLE_THREADS
assert(destructors_set[keynum] == 0);
int k5_key_delete (k5_key_t keynum)
{
- assert(keynum >= 0 && keynum < K5_KEY_MAX);
-
#ifndef ENABLE_THREADS
assert(destructors_set[keynum] == 1);