Compare commits

..

3 Commits
1.0.11 ... 1.0

Author SHA1 Message Date
Kevin P. Fleming
b5c262931d Convert this branch to Opsound music-on-hold.
For more details:
http://blogs.digium.com/2009/08/18/asterisk-music-on-hold-changes/



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.0@212901 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-08-18 20:22:48 +00:00
Kevin P. Fleming
63046de1cb properly handle signed integer input
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.0@45336 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-10-17 17:57:36 +00:00
Kevin P. Fleming
e132aba5c9 correct yesterday's security fix so that it doesn't improperly reject valid video frames
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.0@32565 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-06-06 15:38:44 +00:00
4 changed files with 17 additions and 17 deletions

View File

@@ -1 +0,0 @@
1.0.11

View File

@@ -3,12 +3,6 @@
not listed here. A complete listing of changes is available through
the Asterisk-CVS mailing list hosted at http://lists.digium.com.
Asterisk 1.0.11
-- chan_iax2
-- A security vulnerability that could lead to denial of service attacks
and Asterisk process crashes was fixed in this release.
Asterisk 1.0.10
-- chan_local

View File

@@ -5052,11 +5052,21 @@ static int socket_read(int *id, int fd, short events, void *cbdata)
ast_log(LOG_WARNING, "midget packet received (%d of %d min)\n", res, (int)sizeof(struct ast_iax2_mini_hdr));
return 1;
}
if ((res >= sizeof(*vh)) && ((vh->zeros == 0) && (ntohs(vh->callno) & 0x8000))) {
if ((vh->zeros == 0) && (ntohs(vh->callno) & 0x8000)) {
if (res < sizeof(*vh)) {
ast_log(LOG_WARNING, "Rejecting packet from '%s.%d' that is flagged as a mini video frame but is too short\n", ast_inet_ntoa(iabuf, sizeof(iabuf), sin.sin_addr), ntohs(sin.sin_port));
return 1;
}
/* This is a video frame, get call number */
fr.callno = find_callno(ntohs(vh->callno) & ~0x8000, dcallno, &sin, new, 1);
minivid = 1;
} else if ((res >= sizeof(*meta)) && (meta->zeros == 0) && !(ntohs(meta->metacmd) & 0x8000)) {
} else if ((meta->zeros == 0) && !(ntohs(meta->metacmd) & 0x8000)) {
if (res < sizeof(*meta)) {
ast_log(LOG_WARNING, "Rejecting packet from '%s.%d' that is flagged as a meta frame but is too short\n", ast_inet_ntoa(iabuf, sizeof(iabuf), sin.sin_addr), ntohs(sin.sin_port));
return 1;
}
/* This is a meta header */
switch(meta->metacmd) {
case IAX_META_TRUNK:
@@ -5149,14 +5159,7 @@ static int socket_read(int *id, int fd, short events, void *cbdata)
}
return 1;
}
/* if we got here and ->zeros contains zeros, this cannot be a valid
miniframe or full frame but it wasn't a valid video frame or meta
frame either, so we reject it
*/
if (vh->zeros == 0) {
ast_log(LOG_WARNING, "Rejecting packet from '%s.%d' that is flagged as a video or meta frame but is not properly formatted\n", ast_inet_ntoa(iabuf, sizeof(iabuf), sin.sin_addr), ntohs(sin.sin_port));
return 1;
}
#ifdef DEBUG_SUPPORT
if (iaxdebug)
iax_showframe(NULL, fh, 1, &sin, res - sizeof(struct ast_iax2_full_hdr));

View File

@@ -2305,6 +2305,10 @@ static int get_input(struct skinnysession *s)
return -1;
}
dlen = *(int *)s->inbuf;
if (dlen < 0) {
ast_log(LOG_WARNING, "Skinny Client sent invalid data.\n");
return -1;
}
if (dlen+8 > sizeof(s->inbuf))
dlen = sizeof(s->inbuf) - 8;
res = read(s->fd, s->inbuf+4, dlen+4);