# Disable java in browser

## grant123

I've read that a java-enabled browser is a security risk even on Linux.  How can I be sure I'm not vulnerable?

----------

## charles17

 *grant123 wrote:*   

> I've read that a java-enabled browser is a security risk even on Linux.  How can I be sure I'm not vulnerable?

 

Depends on your browser. Firefox uses java as a plugin.  Type about:plugins in the urlbar to see what plugins are activated.

----------

## grant123

Can I do something Gentoo-wide to disable java in browsers?

----------

## charles17

 *grant123 wrote:*   

> Can I do something Gentoo-wide to disable java in browsers?

 

Have jre and jdk without plugin support or better completely unmerged. No idea if any of your undisclosed browsers has java support without jre or jdk.

And, don't get confused regarding javascript being completely different from java. ok?

----------

## grant123

 *charles17 wrote:*   

>  *grant123 wrote:*   Can I do something Gentoo-wide to disable java in browsers? 
> 
> Have jre and jdk without plugin support or better completely unmerged.

 

I have the jdk and jre virtuals.  How can I figure out which packages they are associated with?

----------

## charles17

```
$ eselect java-nsplugin list
```

----------

## grant123

```
# eselect java-nsplugin list

Available 32-bit Java browser plugins

Available 64-bit Java browser plugins
```

I guess this means I don't have a jdk and jre?  Why would I have the virtuals?  My system is up to date and cleaned.

----------

## charles17

 *grant123 wrote:*   

>   Why would I have the virtuals?  My system is up to date and cleaned.

 Check

```
$ equery d virtual/jdk

$ equery d virtual/jre

$ grep -i 'jre\|jdk' /var/lib/portage/world
```

----------

## grant123

OK I can see that a java program I use does depend on virtual/jre, but then how can it operate without a real jre installed?

----------

## charles17

It cannot.

----------

## grant123

The java program works for sure and I see that I do have dev-java/icedtea-7.2.4.7 installed, so I guess the question is why doesn't 'eselect java-nsplugin list' indicate that?

EDIT: It must be because I'm using USE="-nsplugin".  Is there a method for finding out which jre and jdk are installed?

----------

## charles17

```
$ eselect java-vm list
```

----------

## grant123

It all makes sense now, thank you.

```
# eselect java-vm list

Available Java Virtual Machines:

  [1]   icedtea-7  system-vm
```

----------

