How to manually upload a file with cypress?

I know that there is a plugin for doing this in cypress already. However using it with jar files just corrupts the file and therefore it is useless in my usecase. This is really weird because i tried it with every combination of encoding and it still does not work. Works perfectly fine with other filetypes however.

This is the code i am using (works except with jar files).

cy.get('[data-cy="dropzone"]')
  .attachFile('test.jar', { subjectType: 'drag-n-drop' });

I know that you can perform post requests in cypress. Is it possible to perfom the file upload with it after clicking the dropzone element?