pfSense 2.2.5 CaptivePortal Patch

Patch for pfSense 2.2.5 to redirect proxy users to the authentification portal.

*** captiveportal.inc  Wed Nov 04 22:52:22 2015
--- captiveportal_patched.inc   Mon Dec 14 17:12:42 2015
***************
*** 539,544 ****
--- 539,548 ----
  EOD;
  
    $rulenum = 65310;
+   /* Deny direct access to local services before captive portal authentication */
+   $local_service_ports="3128,3129";
+   $cprules .= "add {$rulenum} skipto 65314 ip from any to table(100) {$local_service_ports} in\n";
+   $cprules .= "add {$rulenum} skipto 65314 ip from table(100) {$local_service_ports} to any out\n";
    /* These tables contain host ips */
    $cprules .= "add {$rulenum} pass ip from any to table(100) in\n";
    $rulenum++;
***************
*** 578,591 ****
        else
            $listenporthttps = 8001 + $cpzoneid;
            if (!isset($config['captiveportal'][$cpzone]['nohttpsforwards'])) {
!               $cprules .= "add 65531 fwd 127.0.0.1,{$listenporthttps} tcp from any to any dst-port 443 in\n";
            }
    }
    
    $cprules .= <<<EOD
  
  # redirect non-authenticated clients to captive portal
! add 65532 fwd 127.0.0.1,{$listenporthttp} tcp from any to any dst-port 80 in 
  # let the responses from the captive portal web server back out
  add 65533 pass tcp from any to any out
  # block everything else
--- 582,596 ----
        else
            $listenporthttps = 8001 + $cpzoneid;
            if (!isset($config['captiveportal'][$cpzone]['nohttpsforwards'])) {
!               $cprules .= "add 65530 fwd 127.0.0.1,{$listenporthttps} tcp from any to any dst-port 443 in\n";
            }
    }
    
    $cprules .= <<<EOD
  
  # redirect non-authenticated clients to captive portal
! add 65531 fwd 127.0.0.1,{$listenporthttp} tcp from any to any dst-port 80 in 
! add 65532 fwd 127.0.0.1,{$listenporthttp} tcp from any to any dst-port 3128 in 
  # let the responses from the captive portal web server back out
  add 65533 pass tcp from any to any out
  # block everything else

Diff created with WinMerge.

Verifying Active Directory Installation

Check the status of the shared SYSVOL

dcdiag /test:netlogons

Verify DNS registration and functionality

dcdiag /test:dns

Verify communication with other domain controllers

nltest /dclist: <domain name>

Verify replication with other domain controllers

dcdiag /test:replications

Verify the availability of the operations masters

dcdiag /s: domaincontroller /test:knowsofroleholders /verbose 
dcdiag /s: domaincontroller /test:fsmocheck

[via]https://technet.microsoft.com/en-us/library/cc781459%28v=ws.10%29.aspx[/via]

How to repair or fully rebuild Windows WMI Repository

For Windows Vista and newer try to run the following:

  1. Verify repo (If the result shown as inconsistent, go to step 2)
    winmgmt /verifyrepository
  2. Repair repo
    winmgmt /salvagerepository
  3. Verify repo to check again wmi repository had been repaired successfully
    winmgmt /verifyrepository

To fully rebuild the WMI Repository follow these steps:

  1. Disable and stop the winmgmt service (Disable is important, elso you can't rename the folder in step 2)
  2. Rename C:\Windows\System32\wbem\repository
  3. Enable and start the winmgmt service
  4. Open a CMD prompt as Administrator
  5. Navigate to C:\Windows\System32\wbem\
  6. Run the cmd (this will take a minute or so to complete)
    for /f %s in ('dir /b *.mof') do mofcomp %s
  7. Now run the cmd
    for /f %s in ('dir /b en-us\*.mfl') do mofcomp en-us\%s
  8. Now run the cmd
    for /f %s in ('dir /b de-DE\*.mfl') do mofcomp de-DE\%s
  9. Restart computer

[via]https://support.software.dell.com/de-de/vworkspace/kb/88861[/via]

ODD drive is not recognized in Windows 8.x/10

After you install Windows 8.x or Windows 10, you may find the CD/DVD drive is not recognized. Resolution:

Open Command Prompt as an Administrator and run the following command:

reg.exe add "HKLM\System\CurrentControlSet\Services\atapi\Controller0" /f /v EnumDevice1 /t REG_DWORD /d 0x00000001

Reboot the system and verify if the problem has been resolved.
[via]http://blogs.technet.com/b/asiasupp/archive/2012/03/22/you-may-experience-that-dvd-drive-is-not-recognized-in-windows-8.aspx[/via]

Disable Apple HFS driver helps with Veeam Entpoint Backup and VSS errors

Do you have problems with Veeam Entpoint Backup or Windows Backup fails with VSS error 12289 on a iMac? Just disable the Apple HFS driver and reboot. I use Autoruns from Sysinternals for that:

After that you have no access to the OS X HFS partitions, but for me this is no problem. I haven't use that any time.

[via]http://www.tenforums.com/general-discussion/4556-cannot-make-system-image-vss-error-12289-a-3.html#post207784[/via]

Install IPKG on a Synology DS415play

I search for a easy guid to install ipkg on my Synology DS415play with Intel Atom CPU. I found a guid by Edward P:

Connect to your NAS as root through SSH
Go to a temporary folder, for example:

cd /volume1/@tmp

Download the bootstrap script:

wget http://ipkg.nslu2-linux.org/feeds/optware/syno-i686/cross/unstable/syno-i686-bootstrap_1.2-7_i686.xsh

Make the downloaded script file executable:

chmod +x syno-i686-bootstrap_1.2–7_i686.xsh

Execute the bootstrap script:

sh syno-i686-bootstrap_1.2–7_i686.xsh

Installation should now be completed. To test it, run:

ipkg update

Enjoy.

[via]https://medium.com/@edwardmp/how-to-install-ipkg-on-a-synology-ds415play-nas-14fa94901275[/via]