Bob Mottram 8 years ago
parent
commit
b6bf112e77
2 changed files with 5 additions and 5 deletions
  1. 2
    2
      src/freedombone-sec
  2. 3
    3
      src/freedombone-utils-onion

+ 2
- 2
src/freedombone-sec View File

752
 }
752
 }
753
 
753
 
754
 function show_tor_bridges {
754
 function show_tor_bridges {
755
-    if ! grep "bridge " /etc/tor/torrc; then
755
+    if ! grep "Bridge " /etc/tor/torrc; then
756
         echo $'No Tor bridges have been added'
756
         echo $'No Tor bridges have been added'
757
         return
757
         return
758
     fi
758
     fi
759
     clear
759
     clear
760
-    grep "bridge " /etc/tor/torrc
760
+    grep "Bridge " /etc/tor/torrc
761
 }
761
 }
762
 
762
 
763
 function add_tor_bridge {
763
 function add_tor_bridge {

+ 3
- 3
src/freedombone-utils-onion View File

435
         echo 'UseBridges 1' >> /etc/tor/torrc
435
         echo 'UseBridges 1' >> /etc/tor/torrc
436
     fi
436
     fi
437
 
437
 
438
-    bridge_str="bridge $bridge_type ${bridge_ip_address}:${bridge_port} ${bridge_key}"
438
+    bridge_str="Bridge $bridge_type ${bridge_ip_address}:${bridge_port} ${bridge_key}"
439
     if ! grep "${bridge_str}" /etc/tor/torrc; then
439
     if ! grep "${bridge_str}" /etc/tor/torrc; then
440
         sed -i "/UseBridges/a ${bridge_str}" >> /etc/tor/torrc
440
         sed -i "/UseBridges/a ${bridge_str}" >> /etc/tor/torrc
441
     fi
441
     fi
447
     bridge_ip_address="$1"
447
     bridge_ip_address="$1"
448
     bridge_type='obfs4'
448
     bridge_type='obfs4'
449
 
449
 
450
-    bridge_str="bridge $bridge_type ${bridge_ip_address}"
450
+    bridge_str="Bridge $bridge_type ${bridge_ip_address}"
451
     if grep "${bridge_str}" /etc/tor/torrc; then
451
     if grep "${bridge_str}" /etc/tor/torrc; then
452
         sed -i "/${bridge_str}/d" /etc/tor/torrc
452
         sed -i "/${bridge_str}/d" /etc/tor/torrc
453
     fi
453
     fi
454
 
454
 
455
     # If there are no bridges remaining then remove UseBridges
455
     # If there are no bridges remaining then remove UseBridges
456
-    if ! grep "bridge " /etc/tor/torrc; then
456
+    if ! grep "Bridge " /etc/tor/torrc; then
457
         if ! grep "#UseBridges" /etc/tor/torrc; then
457
         if ! grep "#UseBridges" /etc/tor/torrc; then
458
             sed -i 's|UseBridges|#UseBridges|g' /etc/tor/torrc
458
             sed -i 's|UseBridges|#UseBridges|g' /etc/tor/torrc
459
         fi
459
         fi