1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-11-10 21:38:50 +01:00

* cert.c (get_cert): Disable IPGP types for now until the format questions

in the draft are settled.

* srv.c (getsrv): Error on oversize SRV responses.
This commit is contained in:
David Shaw 2006-01-26 16:51:04 +00:00
parent 214a3a646e
commit 23cfe019e9
3 changed files with 12 additions and 2 deletions

View File

@ -1,3 +1,10 @@
2006-01-26 David Shaw <dshaw@jabberwocky.com>
* cert.c (get_cert): Disable IPGP types for now until the format
questions in the draft are settled.
* srv.c (getsrv): Error on oversize SRV responses.
2005-12-24 David Shaw <dshaw@jabberwocky.com> 2005-12-24 David Shaw <dshaw@jabberwocky.com>
* cert.c (get_cert): Properly chase down CNAMEs pointing to CERTs. * cert.c (get_cert): Properly chase down CNAMEs pointing to CERTs.

View File

@ -134,6 +134,7 @@ get_cert(const char *name,size_t max_size,IOBUF *iobuf,char **url)
ret=1; ret=1;
break; break;
} }
#if 0
else if(ctype==6 && dlen<1023 && url) else if(ctype==6 && dlen<1023 && url)
{ {
/* Sanity check the IPGP URL type that the URL isn't too /* Sanity check the IPGP URL type that the URL isn't too
@ -145,6 +146,7 @@ get_cert(const char *name,size_t max_size,IOBUF *iobuf,char **url)
ret=2; ret=2;
break; break;
} }
#endif
/* Neither type matches, so go around to the next answer. */ /* Neither type matches, so go around to the next answer. */
pt+=dlen; pt+=dlen;

View File

@ -42,7 +42,8 @@
#define T_SRV 33 #define T_SRV 33
#endif #endif
static int priosort(const void *a,const void *b) static int
priosort(const void *a,const void *b)
{ {
const struct srventry *sa=a,*sb=b; const struct srventry *sa=a,*sb=b;
if(sa->priority>sb->priority) if(sa->priority>sb->priority)
@ -64,7 +65,7 @@ getsrv(const char *name,struct srventry **list)
*list=NULL; *list=NULL;
r=res_query(name,C_IN,T_SRV,answer,PACKETSZ); r=res_query(name,C_IN,T_SRV,answer,PACKETSZ);
if(r<sizeof(HEADER)) if(r<sizeof(HEADER) || r>PACKETSZ)
return -1; return -1;
if((((HEADER *)answer)->rcode)==NOERROR && if((((HEADER *)answer)->rcode)==NOERROR &&