Category : native

im trying to convert this piece of code (c++): PROCESS_MITIGATION_BINARY_SIGNATURE_POLICY signaturePolicy = {}; signaturePolicy.MicrosoftSignedOnly = true; SetProcessMitigationPolicy(ProcessSignaturePolicy, &signaturePolicy, sizeof(signaturePolicy)); Into Java code via JNA. I already got the function SetProcessMitigationPolicy from Kernel32.dll and im able to call it, but how to pass such parameters? Can you please provide an example of it? Thanks in advance! ..

Read more

I have a problem with running my jar execution file built by Intellij Idea Artifacts in command line. Error message is "NoClassDefFoundError: io.mattmoore.kotlin.playground.cinterop.Greeter". But it worked when I use IDE to execute "RUN". Do you have any Idea why is that happening? Highly appreciated if someone could give me a hint about how to fix ..

Read more

I’m trying to run a native method that I created but when I try and run my main method I get this error and I’ve got no clue how to fix it, I 100% know my shared library is being loaded. Exception in thread "main" java.lang.UnsatisfiedLinkError: Main.C.C.change(II)J at Main.C.C.change(Native Method) at Main.C.C.main(C.java:16) Here are all ..

Read more

So I have this c++ code I wish to implement into my java project. Function: change resolution DEVMODE devmode; devmode.dmSize = sizeof(DEVMODE); devmode.dmPelsWidth = desiredWidth; devmode.dmPelsHeight = desiredHeight; long result = ChangeDisplaySettings(&devmode, DM_PELSWIDTH || DM_PELSHEIGHT); I want to implement this into this header file I generated and into its respected function so I can use ..

Read more