Firefoxの権限の分離(別名:Webブラウジングを保護する方法)

Firefoxの権限の分離(別名:Webブラウジングを保護する方法)

私はScientific Linux 6.3でこれを行います(実装に必要な最小限のLinux知識)。

共有ダウンロードディレクトリ

覚えておいてください。このディレクトリではコピーしかできず、ここからファイルを「移動」することはできません!

adduser ffuser
passwd ffuser # use a very good and very long password
groupadd ffgroup
vi /etc/group # add ffuser and the normal user to the end of the ffgroup line. after editing a users group, you need to re-login with it..
mkdir /home/Downloads; chmod -R 2770 /home/Downloads; ln -s /home/Downloads /home/NORMALUSERHERE/Desktop/Downloads; chown ffuser:ffgroup /home/Downloads/
echo "umask 007" >> /home/ffuser/.bashrc
ssh-copy-id -i /home/NORMALUSERHERE/.ssh/id_rsa.pub '-p PORTNUMBER [email protected]'

根がある

vi /etc/ssh/sshd_config
PasswordAuthentication no
PubkeyAuthentication yes
PermitRootLogin without-password
ListenAddress 127.0.0.1
Port SOMEHIGHPORTNUMBERHERE

このワンライナーを使ってFirefoxをダウンロードしてください

URL="https://ftp.mozilla.org/pub/mozilla.org/firefox/releases/latest/linux-x86_64/en-US/"; URLEND=`curl -s $URL | sed 's/"/\n/g' | fgrep '.tar' | sort -nr | egrep -v '/a|align|/td' | head -1`; curl "${URL}${URLEND}" > ${URLEND}"

[GNOME2を使用]ログイン時にffuser / rootが表示されない

sed -i 's/\[greeter\]/\[greeter\]\nExclude=ffuser,root/g' /etc/gdm/custom.conf
cat /etc/gdm/custom.conf

フラッシュ

Flashは本当に必要なときにのみ使用してください。

yum install flash-plugin
# run this with ffuser
mkdir -p "/home/`whoami`/.firefox/plugins"; ln -s "/usr/lib64/flash-plugin/libflashplayer.so" "/home/`whoami`/.firefox/plugins"

これをデフォルトのFirefoxアドオンとして使用してください

https://addons.mozilla.org/en-US/firefox/addon/wot-safe-browsing-tool/ # WOT settings -> Searching -> Show only negative ratings # FOR REAL SECURITY don't use this plugin, because it send out url's that you are visiting..
https://addons.mozilla.org/en-US/firefox/addon/adblock-plus/
https://www.eff.org/https-everywhere
https://addons.mozilla.org/en-US/firefox/addon/flashblock/ # if you are using flash.. but don't use it.. don't install flash..
https://addons.mozilla.org/en-US/firefox/addon/cookie-whitelist-with-buttons/

セキュリティを強化するための追加機能

https://addons.mozilla.org/en-US/firefox/addon/noscript/ # tick the "restrict on trusted sites too" in the "embedded objects" tab
# in 2013.03 convergence didn't worked very well: https sites were slow with it, etc...
http://convergence.io/ # Firefox wouldn't start after installing convergence for the first time, just "kill" Firefox, start it again and then it will be ok :)

情報:構成

app.update.silent
true

network.http.pipelining
true

network.http.proxy.pipelining
true

network.dns.disableIPv6
true

# only if using Linux/BSD
browser.download.manager.scanWhenDone
false

browser.cache.disk.capacity
262144

browser.cache.offline.capacity
262144

layout.spellcheckDefault
2

browser.sessionstore.max_tabs_undo
2

browser.sessionstore.max_windows_undo
2

plugins.hide_infobar_for_missing_plugin
true

# THESE 5 ARE IMPORTANT FOR SECURITY REASONS
geo.enabled
false

network.http.sendRefererHeader
0

pdfjs.disabled
true

# only if using noscript!
noscript.showPermanent
false

New -> String
general.useragent.override
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:19.0) Gecko/20100101 Firefox/19.0
# just don't use your real user agent..

Flash Cookieを無効にする

プライバシー保護のためにFlashがインストールされている場合。行く:

https://www.youtube.com/

Flash要素を右クリックします。

Right click -> Global Settings... -> Storage TAB -> Block all sites from storing information on this computer
Camera and Mic TAB -> Block all sites from using the camera and microphone
Playback -> Block all sites from using peer-assisted networking

その他の重要な構成

  • オプション->詳細->ネットワーク->オフラインストレージ256 MB
  • オプション->詳細->一般->アクセス性->

    起動時にFirefoxがデフォルトのブラウザであることを確認するには、必ず[OK]をオフにしてください。滑らかなスクロールを有効にするを選択解除します。

  • 未使用の検索エンジンを削除してください!

確認してくださいabout:plugins。プラグインがあってはなりません。

rm /usr/lib/mozilla/plugins/*

その後、次のコマンドを使用してFirefoxを起動できます。

ssh -p 52317 [email protected] -X /home/ffuser/.firefox/firefox-bin > /dev/null 2>&1

Firefoxには自動アップデートが組み込まれています。

いくつかの便利なウェブサイト:

次の質問はすべてこのトピックに関連しています(それで、いくつかの質問から始めませんでした)。

  1. セキュリティの観点から、この設定をどのように欺くことができますか? 「ffuser」の権限を減らすためのヒント/コツはありますか?
  2. Firefox は終了後も引き続き実行されます。 Firefoxウィンドウがない場合は、どのようにFirefoxプロセスを閉じますか? (特に問題はなく、ただ苦しいだけです)
  3. Firefoxで「ssh -X」と入力すると音は出ません。この問題をどのように解決しますか?

ベストアンサー1

  1. 仮想マシンにアクセスできる場合は設定が簡単になりますが、中断するのは少し難しいです。 RH派生製品を使用しているため、VMソフトウェアに適用されるSELinuxルールの利点を享受できます。 SELinuxルールの理論上の利点を活用して、Fedoraを使用してFirefoxの配布パッケージのバージョンを取得するなど、他のゲストシステムを実行することもできます。

  2. おそらくdbusでしょう。実行してみてくださいdbus-launch firefox

  3. パルスオーディオがありますか?ローカルネットワークでssh -Xを使用してネットワークpulseaudioを有効にすると、サウンドも処理することがわかりましたpaprefs。 (どれだけ拡張可能かはわかりません)。健全なプライバシーが問題である場合は、この点をより慎重に検討することをお勧めします。

おすすめ記事