Click or drag to resize

HttpUtilsGetSafeMimeTypeValue Method

Returns a sanitized Media Type string that is ready to be used as a Response.ContentType value. This is to avoid XSS attacks with user-provided Media Type strings.

Namespace:  PDTec.IceNet.Sdk.Utils
Assembly:  PDTec.IceNet.Sdk (in PDTec.IceNet.Sdk.dll) Version: 7.2.0.0 (7.2.7583.15464)
Syntax
C#
public static string GetSafeMimeTypeValue(
	string mimeType
)

Parameters

mimeType
Type: SystemString
The Media Type input.

Return Value

Type: String
The sanitized Media Type string. Defaults to application/octet-stream if illegal characters were detected in mimeType.
See Also