Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

bat script

Posted on 2011-05-05
6
Medium Priority
?
935 Views
Last Modified: 2013-01-31
We need to import a certificate in mozilla firefox databse for all users ( 500).
I am trying to do this with logon script,need asistance for doing it with bat or vbs .

file location :  \\domain\netlogon\cert8.db
destitation : %APPDATA%\mozilla\firefox\profiles\&&&&&&(random)default\

Appreciate some short and easey method.

thanks
0
Comment
Question by:auk_experts
  • 3
  • 2
6 Comments
 

Author Comment

by:auk_experts
ID: 35696097
It should be usable through logon script method or GPO
0
 
LVL 86

Expert Comment

by:oBdA
ID: 35696175
Try this:
@echo off
setlocal
set TargetFolder=%APPDATA%\mozilla\firefox\profiles
set File=%LogonServer%\netlogon\cert8.db
for /d %%a in ("%TargetFolder%\*.default") do copy "%File%" "%%~a"

Open in new window

0
 

Author Comment

by:auk_experts
ID: 35696192
Thanks , it looks to be working fine. I need to put some condition that if the target folder is not available it should end without error.

and do you know the location of default location of cert8.db for firefox.

0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
LVL 86

Accepted Solution

by:
oBdA earned 2000 total points
ID: 35696233
This version only copies if there's a default folder:
@echo off
setlocal
set TargetFolder=%APPDATA%\mozilla\firefox\profiles
set File=%LogonServer%\netlogon\cert8.db
if exist "%TargetFolder%\*.default" (
  for /d %%a in ("%TargetFolder%\*.default") do copy "%File%" "%%~a"
)

Open in new window

You mean the location of the "template" cert8.db when creating a new profile? I'd have guessed somewhere in the main program folder, but I don't know a lot about Firefox, using mostly Opera, sorry ...
0
 

Author Comment

by:auk_experts
ID: 35696318
Thanks , will test it and try to find teh template of cert8.db.
Once i do i will close it with your solution.

0
 

Expert Comment

by:kev21111
ID: 38839269
Here is the easiest and safest way to do this. We have over 200,000 machines with Firefox but want to keep the IE certificates synced with Firefox.

Create new folder where admin rights are not needed, ie. C:\profiles or wherever your OS teams says you can create a folder

Make sure you have imported the certificates from IE or where ever you want to import them from. You may also have to hit individual site just to get them in your cert8.db

Copy the cert8.db from %appdata%\Roaming\Mozilla\Firefox to the new folder C:\profiles

Modify the Firefox startup to look like this "C:\Program Files\Mozilla Firefox\firefox.exe" -profile "c:\profiles"

When Firefox is launched, it will now use the cert8.db you copied earlier.
This is effective, safe and works!
Good Luck
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

By default Outlook 2016 displays only one time zone in the Calendar. The following article explains how to display two time zones in one calendar view.
In this tutorial, we’re going to learn how to convert Youtube to mp3 for Free. We'll show you how easy it is to make an mp3 from your video clips so that you can enjoy them offline.
This Micro Tutorial will give you a basic overview of Windows DVD Burner through its features and interface. This will be demonstrated using Windows 7 operating system.
In this video, viewers will be given step by step instructions on adjusting mouse, pointer and cursor visibility in Microsoft Windows 10. The video seeks to educate those who are struggling with the new Windows 10 Graphical User Interface. Change Cu…
Suggested Courses

580 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question