Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Mapping file extension with mime type

Armando4
Tera Contributor

Hi All,

I need to upload a file containing the SSH Public Key on ServiceNow, it has a .pub extension (with text/plain content).

 

I added that extension to the glide.attachment.extensions property but it seems it's not enough because i got an error that says "File type not permitted or mime type does not match the file content".

 

I know that the .pub extension is also for MS Publisher, so i think i'm passing a plain/text file while ServiceNow expects the Publisher mime type.

I found this property: glide.security.mime_type.extension_mapping in which i can map the extension with the mime type, so I wrote in the value:

 

Armando4_0-1764761874601.png

But no luck, same error.

Any suggestions?

 

Thanks

 

0 REPLIES 0