[Git][NTPsec/ntpsec][cookie] ntpd/nts_cookie.c: restore previous comment indents
Gary E. Miller (@garyedmundsmiller)
gitlab at mg.gitlab.com
Wed Aug 5 04:30:31 UTC 2026
Gary E. Miller pushed to branch cookie at NTPsec / ntpsec
Commits:
7595b7b6 by Gary E. Miller at 2026-08-04T21:30:02-07:00
ntpd/nts_cookie.c: restore previous comment indents
No functional changes.
- - - - -
1 changed file:
- ntpd/nts_cookie.c
Changes:
=====================================
ntpd/nts_cookie.c
=====================================
@@ -90,7 +90,7 @@
* You can change that by editing the keys file.
*/
int K_length = AEAD_AES_SIV_CMAC_256_KEYLEN;
-time_t K_time = 0; // time K was created, 0 for none
+time_t K_time = 0; // time K was created, 0 for none
struct NTS_Key nts_keys[NTS_nKEYS];
int nts_nKeys = 0;
@@ -173,7 +173,7 @@ bool nts_read_cookie_keys(void) {
if (NULL == in) {
char errbuf[100];
if (ENOENT == errno)
- return false; // File doesn't exist
+ return false; // File doesn't exist
ntp_strerror_r(errno, errbuf, sizeof(errbuf));
msyslog(LOG_ERR, "NTSs: can't read old cookie file: %s=>%s",
cookie_filename, errbuf);
@@ -296,7 +296,7 @@ int nts_make_cookie(uint8_t *cookie,
size_t left;
if (NULL == cookie_ctx)
- return 0; // We aren't initialized yet.
+ return 0; // We aren't initialized yet.
nts_cnt.cookie_make++;
@@ -332,7 +332,7 @@ int nts_make_cookie(uint8_t *cookie,
nts_lock_cookielock();
ok = AES_SIV_Encrypt(cookie_ctx,
- finger, &left, // left: in: max out length, out: length used
+ finger, &left, // left: in: max out length, out: length used
nts_keys[0].K, K_length,
nonce, NONCE_LENGTH,
plaintext, plainlength,
@@ -371,7 +371,7 @@ bool nts_unpack_cookie(uint8_t *cookie, int cookielen,
int i;
if (NULL == cookie_ctx)
- return false; // We aren't initialized yet.
+ return false; // We aren't initialized yet.
if (0 == nts_nKeys) {
nts_cnt.cookie_not_server++;
@@ -383,7 +383,7 @@ bool nts_unpack_cookie(uint8_t *cookie, int cookielen,
return false;
finger = cookie;
- key = NULL; // squash uninitialized warning
+ key = NULL; // squash uninitialized warning
for (i=0; i<nts_nKeys; i++) {
key = &nts_keys[i];
if (0 == memcmp(finger, &key->I, sizeof(key->I))) {
View it on GitLab: https://gitlab.com/NTPsec/ntpsec/-/commit/7595b7b6ff7030b8187fe89f262caa18c20eec1b
--
View it on GitLab: https://gitlab.com/NTPsec/ntpsec/-/commit/7595b7b6ff7030b8187fe89f262caa18c20eec1b
You're receiving this email because of your account on gitlab.com. Manage all notifications: https://gitlab.com/-/profile/notifications | Help: https://gitlab.com/help
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ntpsec.org/pipermail/vc/attachments/20260805/e0b3d5b8/attachment-0001.htm>
More information about the vc
mailing list