lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <df512b811ee2df6b8f55dd2a9fb0178e6e5c490f.camel@talbothome.com>
Date:   Sat, 10 Apr 2021 10:20:19 -0400
From:   Chris Talbot <chris@...bothome.com>
To:     ofono@...no.org, netdev@...r.kernel.org,
        debian-on-mobile-maintainers@...oth-lists.debian.net,
        librem-5-dev@...ts.community.puri.sm
Subject: [PATCH 2/9] Ensure Compatibility with Telus Canada

Telus Canada makes mmsd decode a header that is not in the standard.
This patch allows this header to be decoded and allows for MMS support
in Telus Canada.
---
 src/mmsutil.c | 16 ++++++++++++----
 1 file changed, 12 insertions(+), 4 deletions(-)

diff --git a/src/mmsutil.c b/src/mmsutil.c
index 5fcf358..9430bf1 100644
--- a/src/mmsutil.c
+++ b/src/mmsutil.c
@@ -732,10 +732,9 @@ static header_handler handler_for_type(enum
mms_header header)
 		return extract_text;
 	case MMS_HEADER_INVALID:
 	case __MMS_HEADER_MAX:
+	default:
 		return NULL;
 	}
-
-	return NULL;
 }
 
 struct header_handler_entry {
@@ -781,8 +780,17 @@ static gboolean mms_parse_headers(struct
wsp_header_iter *iter,
 
 		handler = handler_for_type(h);
 		if (handler == NULL) {
-			DBG("no handler for type %u", h);
-			return FALSE;
+			if(h == MMS_HEADER_INVALID) {
+				DBG("no handler for type %u", h);
+				return FALSE;
+			} else if (h == __MMS_HEADER_MAX) {
+				DBG("no handler for type %u", h);
+				return FALSE;
+			} else {
+				/*  Telus has strange headers, so this
handles it */
+				DBG("type isn't a part of the
standard? Skipping %u", h);
+				continue;
+			}
 		}
 
 		DBG("saw header of type %u", h);
-- 
2.30.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ