Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (107)
games submitted by our members
Games in WIP (535)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Avoid Keylogger  (Read 3537 times)
0 Members and 1 Guest are viewing this topic.
Offline Marvin Fröhlich

Senior Member




May the 4th, be with you...


« Posted 2008-05-04 01:03:13 »

Hi

To add Joystick support to my input abstraction I use JInput. Since JInput's Mouse doesn't produce input events in a stable way (at least on Linux) And the Keyboard localization doesn't work properly, I have mixed modes, where the Keyboard and Mouse are polled through other  APIs like AWT or LWJGL and just the Joysticks are handled by JInput. Unfortunately there's no way to query the list of Keyboards or the list of Mouses only in JInput. You can only query the list of Controllers and have to filter for Keyboards or Mouses. In principle this is not a problem. But unfortunately some anti-virus tools (like Kaspersky) seem to detect a keylogger (which a JInput keyboard certainly is), if a Keyboard instance is created.

Is there a way to avoid that? I guess, if I was able to query the list of Keyboards/Mouses/Joysticks separately and instances of the different types would only be created, if needed, the problem would be solved.

Thanks in advance.

Marvin
Offline Eli Delventhal

JGO Kernel


Medals: 42
Projects: 11
Exp: 10 years


Game Engineer


« Reply #1 - Posted 2008-05-04 10:21:33 »

I typically loop through all the controllers once and then store the keyboard under and instance variable. Will doing that alleviate your problem? I've never had any issues with anti-virus software, so I'm not the exact nature of this.

See my work:
OTC Software
Offline Marvin Fröhlich

Senior Member




May the 4th, be with you...


« Reply #2 - Posted 2008-05-04 13:48:22 »

I typically loop through all the controllers once and then store the keyboard under and instance variable. Will doing that alleviate your problem?

This is of course the exact same way, that I do it. Is there a different way? I loop through the list of controllers, check for the type, store the instances locally, that I am interested in, and ignore the others. But at this point in time the Keyboard instance is already created, which seems to be enough for it to be detected as a keylogger.

Marvin
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Eli Delventhal

JGO Kernel


Medals: 42
Projects: 11
Exp: 10 years


Game Engineer


« Reply #3 - Posted 2008-05-04 21:08:46 »

Huh, that's interesting. I'd imagine that if this is the way JInput works then there is nothing you can do aside from turning off your key logger detector software. But at the same time it seems like I would have heard of other complaints like this before, especially for people trying to run our games. LWJGL also uses JInput.

See my work:
OTC Software
Offline Marvin Fröhlich

Senior Member




May the 4th, be with you...


« Reply #4 - Posted 2008-05-04 23:18:23 »

LWJGL also uses JInput.

Yes. For Controller handling (where a Controller is a Joystick, SteeringWheel, etc., but not a Keyboard or Mouse).

Marvin
Offline endolf

JGO Coder


Medals: 7


Current project release date: sometime in 3003


« Reply #5 - Posted 2008-05-05 20:21:41 »

I've not heard of JInput triggering AV software, but I can understand why it might. LWJGL also uses JInput as pointed out, and does it the way you do, so I can't see how LWJGL would not trigger the AV software. I'm assuming it scans the DLL when the system loads it, so I can't see how *not* reading the controllers would change anything.

Endolf

Offline Marvin Fröhlich

Senior Member




May the 4th, be with you...


« Reply #6 - Posted 2008-05-06 00:02:09 »

LWJGL also uses JInput as pointed out, and does it the way you do, so I can't see how LWJGL would not trigger the AV software.

It does as for Controllers.
Offline endolf

JGO Coder


Medals: 7


Current project release date: sometime in 3003


« Reply #7 - Posted 2008-05-06 08:29:09 »

Hi

My point was that it's not the creation of the Keyboard instance that fires off the AV software, but the extraction from the jar of the native dll. I can't see a way around that as the DLL will always be in the jar, even if it's unused.

Endolf

Offline Marvin Fröhlich

Senior Member




May the 4th, be with you...


« Reply #8 - Posted 2008-05-07 02:38:45 »

My point was that it's not the creation of the Keyboard instance that fires off the AV software, but the extraction from the jar of the native dll. I can't see a way around that as the DLL will always be in the jar, even if it's unused.

Well, I am still using an older version of JInput, that works without any natives. I just never got the current version to work. I am using the version, that is shipped with LWJGL. And I assume, the one, who reported this issue to me, is using this version of JInput, too.

So, it should not be the existence of a native (dll).

Is there anything I can do to help you find this out? Could you possibly give me some testcode, that I could run (resp. forward the testcode to the one, who reported this issue)?

I guess, it would help, if you could give me the minimum code, that is necessary to check, if a device is a Keyboard/Mouse/Joystick, etc. Is that possible?

Marvin
Offline endolf

JGO Coder


Medals: 7


Current project release date: sometime in 3003


« Reply #9 - Posted 2008-05-13 08:03:01 »

Hi

There never has been a version of JInput that has worked without natives, unless you mean you are only shipping the AWT plugin, which should still work. That would probably support internationalisation too.

If you are saying that the older versions didn't do this, then it might be the RAW plugin thats causing the AV software to fire off. In which case, remove the raw dll from the distribution and pass the right property to load just the directx plugin on windows, you can load the AWT one if you want also.

HTH

Endolf

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Marvin Fröhlich

Senior Member




May the 4th, be with you...


« Reply #10 - Posted 2008-05-15 00:47:04 »

Hmm... That's strange. The version, I am using definitely doesn't use/need natives. Just checkout Xith3D or JAGaToo from sourceforge and see it your self.

I'm also pretty sure, that the AWT plugin isn't used, since it doesn't find any Controllers (Joysticks), if the device nodes don't get applied rw-privileges for everybody (which is still a very annoying thing).

How can I remove the RAW plugin? DirectX is obviously not an option, since I am not working on Windows Wink. And I definitely don't want to use the AWT plugin, since AWT SUCKS in terms of game input. But what if I used the AWT plugin? Are Joysticks still available? If they are, are they retrieved through a different plugin, while Mouse nad Keyboard are accessed through the AWT plugin? that would definitely be an option, since I anyway want to use only the Joysticks through JInput.

BTW. How do you control the mouse in the AWT plugin? If the mouse is used as a relative one (invisible cursor, only deltas in the events), how do you do that? In my AWT abstraction I am using the Robot class, which produces events by itself, which makes it pretty hard to handle.

Marvin
Offline endolf

JGO Coder


Medals: 7


Current project release date: sometime in 3003


« Reply #11 - Posted 2008-05-15 19:56:52 »

Ok, I'm confused now. Lets rewind to basics.

There are 5 plugins for JInput, mac, linux, Raw input on windows, direct x on windows, and AWT. All plugins except the AWT one require a native library. Raw input on windows is the newest addition and at one point did not exist. AWT and Raw input plugins are only used for keyboards/mice. There is another plugin that combines the mice/keyboards from Raw and excludes them from directx.

If the natives are not there, you're not getting controllers through jinput.

What version is fine, what version is not, what platform is the issue on?

Cheers

Endolf

Offline Marvin Fröhlich

Senior Member




May the 4th, be with you...


« Reply #12 - Posted 2008-05-20 22:36:52 »

If the natives are not there, you're not getting controllers through jinput.

Controllers are working fine without natives. Please checkout JAGaToo and run the InputTest. You will see, that no JInput natives are used are controllers do still work.

What version is fine, what version is not, what platform is the issue on?

I only used the version, I am talking about (from the LWJGL distribution) and a year ago I tried the latest built, but without success.

The platform, on which the keylogger-issue arose, is Windows (XP I guess). Please see this thread.

Marvin
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

pw (37 views)
2014-07-24 01:59:36

Riven (38 views)
2014-07-23 21:16:32

Riven (26 views)
2014-07-23 21:07:15

Riven (28 views)
2014-07-23 20:56:16

ctomni231 (59 views)
2014-07-18 06:55:21

Zero Volt (50 views)
2014-07-17 23:47:54

danieldean (42 views)
2014-07-17 23:41:23

MustardPeter (44 views)
2014-07-16 23:30:00

Cero (60 views)
2014-07-16 00:42:17

Riven (57 views)
2014-07-14 18:02:53
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!