Sunday, 11 February 2018

How to Download and Save Videos from a Website

I recently watched a free video embedded in a website and wanted to save the video itself for future reference (imagine the nerve!). The video content was delivered via the Brightcove player and was not a Flash/.swf file which I could otherwise deal with using traditional video download tools or shonky websites. The video was in fact, I believe, an HLS m3u8 video… admittedly, I don’t know if those are the same thing, or for that matter, what they are, and I don’t particularly care.

Rather than download a suspicious installer and infect my computer with the latest crypto virus, TubeOffline provided a handy and relatively simple tutorial using the ever trusty (and trustworthy) VLC media player. I’m reproducing the steps here in simple terms for future reference.

  1. Firstly, find the URL to the .m3u8 file you want to save. In Chrome, hit F12 and go to the Network tab. Check the Disable Cache button. Make sure the Record Network Log button is red and type “m3u8” (without quotes) in the Filter box. Load (or reload the page containing the video you’re after) and have a look at the network log. I grabbed the URL to the master.m3u8 file (right-click, Copy > Copy link address).
  2. From the Media menu in VLC, select Open Network Stream. It should open to the Network tab
  3. Copy the URL of the .m3u8 file to be downloaded and paste it in to the Network URL box. Don’t click the Play button!
  4. Click on the arrow next to the Play button and select Stream
  5. Click Next on the Source screen
  6. At the Destination screen, ensure the destination is set to File and click the Add button. Browse to the location where you want to save your downloaded video and specify a file name. The Save as type box will be left as Containers.
  7. On the Transcoding Options screen, de-select the Active Transcoding checkbox. Leave Profile set to the default (Video – H.264 + MP3 (MP4)
  8. On the Option Setup screen, leave the Stream all elementary streams checkbox de-selected. Click the Stream button.
  9. VLC will begin saving the video to the selected file. Don’t try and play the video and don’t touch anything until the blue progress bar in VLC has reached the end. You can monitor the file itself by hovering over in the file system to keep an eye on its size.

In practice, I noticed the blue progress bar reached the end and the file size was showing as 132MB. I thought it was all finished at that stage but opening the .mp4 file to review in a new VLC instance opened a whole of nothing with a duration zero seconds. After another minute or so, the file size bumped up to 133MB and opening the file again revealed the downloaded video complete with audio. I’ve found closing the original VLC instance seems to finalise the download/flush the last few bits to file. Your mileage may vary.

Tuesday, 5 September 2017

How to save a video from Facebook

If you want to download and save a video from Facebook, right-click on the video and click the option to ‘Show video URL’; copy the link to your clipboard--it will look something like this:

On a PC, paste the link into your browser’s address bar and replace ‘www’ with ‘mobile’ and hit go or enter. The URL will look like this:

The mobile page will load and you can then right-click on the video and click ‘Save video as…’

Thursday, 31 August 2017

How to access KeePass passwords from Chrome

Installing KeePassHttp with a browser extension isn’t difficult. Here are the simple steps:

  1. If your portable KeePass 2.x directory doesn’t have a “Plugins” directory, create it.
  2. Download the KeePassHttp.plgx file from GitHub (you’ll find a link to this file under the heading Non-Windows / Manual Windows Installation)—there’s no need to build, install Chocolately, etc. Save the .plgx file to your KeePass Plugins directory and restart KeePass if running.
  3. Add to the chromelPass extension to Chrome and click the button to connect. In KeePass, you’ll be prompted to name the key request which comes from the Chrome extension—I called mine chromelPass.
  4. Generate unique passwords to replace the single password you use everywhere.

Sunday, 11 June 2017

PDF Toolkit (PDFTK) Examples

I started using PDFtk Free recently, which includes the PDFtk command-line tool PDFtk Server. Although PDFtk Free includes a user interface, it’s pretty basic unless you upgrade to PDFtk Pro (which admittedly doesn’t cost much).

As I’m on a scanning bent, I’ve got lot of PDFs to sort through and, for me, the command line is far more efficient than fiddling with a UI. The command line interface is also extremely simple to use.

Here you’ll find my boilerplate commands for accomplishing various tasks. All commands are non-destructive and create a new document rather than overwriting one of the input files.


Join a second document to the end of another PDF.

pdftk 1.pdf 2.pdf cat output out.pdf

Insert page(s) from another Document

Insert one or more pages from one PDF into a master document.

pdftk A=MasterFile.pdf B=FileToInsert.pdf cat A1-12 B1-7 A13-end output NewFile.pdf

Replace Page(s)

Replace one or more pages in a master document with specific pages from another document.

pdftk A=MasterFile.pdf B=FileToInsert.pdf cat A1-12 B1 A14-end output NewFile.pdf

Collate Scanned Odd and Even Pages (Even Pages in Reverse Order)

Interleave the pages from one document into another, where the pages in the second are reversed (for example when scanning both sides of a two-side document on a scanner that can’t flip pages automatically to scan the back of each page).

pdftk A=odd.pdf B=even.pdf shuffle A Bend-1 output collated.pdf

Extract Page(s)

Extract one or more pages from one PDF into a new document.

pdftk A=in.pdf cat A1-10 A15 A17 output out.pdf

Rotate 180 Degrees

Rotate one or more pages in a PDF 180 degrees. Use ‘east’ instead of ‘south’ to rotate 90 degrees instead.

pdftk in.pdf cat 1-endsouth output out.pdf

Sunday, 16 April 2017

How to specify credentials to restart or shutdown a remote host with ‘net use’

I recently wanted to shutdown a server on my local network (notably a workgroup) using the Windows shutdown command but encountered an access denied error (or no feedback whatsoever).

I needed to use the administrator credentials of the remote server but shutdown.exe doesn’t accept credentials.

Using ‘net use’ to connect to the IPC$ share on remote host, you can set then call shutdown in that security context:

net use \\hostname\IPC$ mypassword /User:administrator
shutdown /r /t 60 /m \\hostname /f

In the net use command above, replace hostname with the name of your remote host (or maybe an IP address), replace mypassword with the password for the account you’re using, and replace administrator with the name of the local account on the remote host you wish to use (which presumably has the necessary rights to restart or shutdown the server).

In the shutdown command above, replace hostname with the name of your remote host, as per the net use command.

Note: Read the shutdown /? usage. The /r flag will restart the host; change /r to /s if you want to shutdown instead. Other parameters can also be specified. I also typically set the timeout (/t) flag to 0 (zero).

I call both commands back-to-back in a Windows Command Prompt, without running the console as Admin.

See below for a few more tips, links, and PowerShell alternatives.

If you’re used to operating as a domain user you may be asking why any of this is even necessary. It’s necessary in a workgroup context because the remote host has no idea who I am if I just tell it to shutdown from some other computer on the local IP network. It may be possible to an account on one host the necessary privileges on another host but I don’t know for certain and, in my limited experience, this can get hard and weird very quickly!

I used to run a domain controller on my small local network (just for fun) and all of my servers were members of a domain, which made security easy. I got rid of the DC as DHCP and other services were migrated to my internet router and to streamline things. In all regards, having one less server to manage, power, and so on is great. I’ll run a virtualised AD when I need to, e.g. for development purposes).

In addition to a media centre, I also still run a physical file server, primarily for backups. My basic process is to power on the file server once a week to backup the media centre, my laptop, etc and then shut it down again (so the kids don’t fiddle and to keep the noise down).

The backup process is otherwise seamless—the backup services on the file server and clients just pick up where they left off and run to completion without any human interaction (I use CrashPlan and would highly recommend it). I only need to power on the file server and then shut it down.

To shut down, I’d previously connect to the file server via Remote Desktop and then shut down. But that’s too hard. I can tell from the backup client on my laptop when a backup is complete so I just want to quickly shutdown the file server and go to bed.

In a domain environment, I could make sure my domain account was a member of the Administrators group on the file server and then call shutdown.exe from a command prompt on my laptop; without the DC, I need to explicitly provide shutdown.exe with the necessary credentials before actually calling shutdown.exe.

A few other notes: the file server is running Windows Server 2012 and my laptop is running Windows 8.1.

In recent versions of Windows (i.e. 2012+), I’ve read that UAC may interfere with things. You may want to turn it off but can simply add or configure this registry key (I didn’t have to):

Value: LocalAccountTokenFilterPolicy
Data: 1 (to disable) or 0 (to enables filtering)
Type: REG_DWORD (32-bit)

You may need to restart after making this change.

Thank to for this one. See also this Microsoft help article (ID 951016) “Description of User Account Control and remote restrictions in Windows Vista”

Others suggested File and Printer sharing must be allowed in the Windows Firewall.

I believe PowerShell offers similar restart (and stop) commands. I haven’t tried them and can’t say whether they work with the techniques described here but I believe both accept a –credential parameter.

See these references:

Sunday, 12 March 2017

Can’t unpin an Office item from the jump list

I recently ran into an issue with a pinned Excel 2016 document that wouldn’t go away. I’d pinned it to the Excel jump list (on the Windows 8.1 task bar) and despite clicking the ‘Unpin from this list’ icon next to the document itself, it was well and truly “stuck”.


I tried simply unpinning the Excel icon from the taskbar but that didn’t help. I installed Windows and Office updates and rebooted but the document kept appearing.

A bit of searching led me to the AutomaticDestinations folder, which can be safely (?) cleared from a command line like so:

del /F /Q %APPDATA%\Microsoft\Windows\Recent\AutomaticDestinations\*

Copy or type the above as one line into a command prompt.

Note this is likely a hidden folder but despite having Explorer configured to show hidden items, I couldn’t see it within the Recent folder.

This command comes from the tutorial (option 3) at, which also contains a second delete command for CustomDestinations and suggests logging off/rebooting for full effect. I didn’t need to run this second command or reboot. You may find it helpful if the above delete command doesn’t work on its own in your case.

It’s important to be aware your pinned jump lists for other applications will also be cleared, included Explorer.

Wednesday, 14 December 2016

Windows Update errors: WindowsUpdate_80244019 and WindowsUpdate_dt000

In Windows Server 2012 R2 Windows Update recently decided to stop working and referred me to the WindowsUpdate_80244019 and WindowsUpdate_dt000 error codes.

An thread eventually got to the point and my issue was quickly resolved with an ipconfig /flushdns command at the command prompt.

Monday, 18 April 2016

Enabling Windows File History (aka Shadow Copy on Win 8) without an external drive or network drive

After being hit by a crypto/ransomware trojan, I’m looking at all options to make file management and backups easier and automatic. Shadow Copy is mentioned frequently in relation to the crypto locker virus (…in that the virus typically deletes shadow copies…) so I thought I’d look into this Windows feature. I’ve been after a version history, of sorts, for regular file content for a while so this sort of helps.

In Windows 8, Shadow Copy was renamed File History and is switched off by default. To switch it on, you need an external drive or a network location but that’s lame so I sought a workaround to test the waters and get up and running on an internal drive.

This blog post details the steps to set this up, which basically entails creating a virtual drive in Windows Disk Management, initialising it and creating a simple volume, and then pointing File History (via Control Panel) to that VHD.

This is by no means a bulletproof solution and I noticed the crypto virus that attacked my machine also encrypted my virtual machines so this .vhd would not be immune. But it’s about defence in depth, I suppose.

Although I gave the VHD solution a spin, it’s not for everyone and, most importantly, they’re not attached automatically when you reboot (without a startup script, that is). Instead of the VHD approach, I created a new folder to contain my file history, shared it (granting Read and Change share permissions to my Windows account), and then pointed File History the share via \\\FileHistory [or whatever you name your share].

Update (a few days on): well that didn’t last. File History very quickly consumed all available free space on my internal laptop drive (a second partition). So I’ve turned it off and am using CrashPlan instead (despite the Java dependency—grrrr) as there was no interface to configure how much storage it uses. File History seems to be yet another one of those inane Windows features that is absolutely useless in real life.

Tuesday, 5 April 2016

Disconnect or remove a website from Google Analytics

To clean up Google Analytics and remove web sites you’re no longer interacting with (e.g. client sites to which you’ve been granted access),  you can simply remove yourself in the User Management screen.

To get there, log in and click on the Admin tab at the top of the Google Analytics screen.

Select the Account you want to rid of from the drop down list in the left column. Then click on the User Management link below.

You should then see a big blue button that says Remove myself from this account. Click it, confirm, and you’re done.

No deletion or trashing of views or properties (but also no undo).

Remove myself from this account

Sunday, 3 January 2016

Change the location where iTunes backups are stored

iTunes annoyingly stores backups on the main system drive (c:\); the backups can get quite large but there seems to be no way within iTunes to set the backup location explicitly.

Scott Hanselman details the steps necessary to create a NTFS junction point to redirect the backup directory to a another drive using mklink but the mklink command only worked when I renamed the /Backup directory in my C:\Users\{user name}\AppData\Roaming\Apple Computer\MobileSync directory to /BackupOld. Prior to the rename, mklink would fail with a “Cannot create a file when that file already exists” error.

The mklink command I used was:

mklink /J "C:\Users\Michael\AppData\Roaming\Apple Computer\MobileSync\Backup" "D:\Backup\iTunes"