CVE-2026-46429 (GHSA-fqpv-mq26-pr4j, CWE-434 Unrestricted Upload of File with Dangerous Type) affects GeoNode <= 5.0.2 and is fixed in 5.0.3 by commit 239a6b4 ("Cumulative upload improvements", PR #14223) and its backport 16ec8b3 (PR #14224). The root cause is that every upload entry point in the vulnerable version trusted the client-supplied filename/extension instead of the file's real content. GeoNode stores documents/datasets and serves them back, so a file whose actual bytes are a dangerous type (HTML/JS for stored XSS, PE/executables, malicious archives) but which carries an allowed extension (e.g. fake.pdf, fake.shp) passed the extension-only validation and got persisted and served.
The patch fixes this by introducing a content-based validation layer (new geonode/upload/uploadhandler.py:FileValidationUploadHandler, geonode/upload/validation/*, per-handler upload_validation_config properties, BaseImporterSerializer.validate_base_file / validate_safe_zip, and the DOCUMENT_MAGIC_MIMETYPE_MAP). Those classes/methods are the mitigation that was ADDED, so they are not the vulnerable functions. The vulnerable functions are the pre-existing upload handlers that were MODIFIED or REMOVED because they processed the untrusted upload without that check:
- geonode.documents.api.views.DocumentViewSet.perform_create — removed entirely by the patch. It accepted file_path/doc_file and validated only the filename suffix against ALLOWED_DOCUMENT_TYPES before cloning the file into storage, so the API document upload could store a dangerous file (and even pull an arbitrary server-side path via file_path).
- geonode.upload.api.views.ImporterViewSet.create — patched to consult request.upload_validation_error and raise ValidationError before cloning base_file. Previously it cloned and processed the uploaded file with no content inspection.
- geonode.documents.views.DocumentUploadView.post — patched to force request.FILES (running the new handler) and return 400 on a validation error. Previously it delegated straight to the CreateView with only the form's extension check (DocumentCreateForm.clean_doc_file), which is the "upload service validation" that could be circumvented with a specially crafted request.
These are the functions that would appear in a Python runtime profile/stack trace while the upload (and the malicious file storage/serving) is being triggered. Python profilers report them as Class.method (namespace/module path stripped): DocumentViewSet.perform_create, ImporterViewSet.create, DocumentUploadView.post.