Calendar interface in Nextcloud

The problem with purism

At heart, I’m a Linux guy.  For many tasks, I use Emacs (a popular editor among some developers due to its extensibility), with Orgmode as my primary means of managing tasks, recording time, jotting down notes and, at times, trying to manage my calendar.

But there were several problems with this. Firstly, the only mobile client to sync Orgmode files with reasonable reliability, was MobileOrg.  Sadly, this project has been discontinued for a while, and to my knowledge it hasn’t yet seen a superior successor.  In addition, Orgmode is a great calendar within Emacs, but it’s not so strong outside. And while MobileOrg was “ok”, it didn’t present information in a convenient, easily-interpreted way.

In short, having a text-only, Linux/Android-only solution, was awkward.

The compromising advantage

Part of the appeal of Orgmode and MobileOrg was being able to keep all data within one’s own infrastructure.  As one of MobileOrg’s features is to “sync files from an SSH server”, and Emacs has TRAMP for accessing network locations, this made it possible to get each end talking with the other, and the synchronisation was generally reliable.

But in some ways, using Emacs, Orgmode and MobileOrg – to achieve data security and ultimate privacy – is arguably a case of the tail wagging the dog.  Was this the only private-data solution? Probably not. Was it the most convenient?  Was Orgmode the right tool for many of life’s repeatable, short-lived events? Definitely not.

image of org-mode
org-mode in action: showing a list of links

Despite trying to use only free, libre & open source software to address this requirement, around 2016 it started becoming clear that simpler solutions existed – albeit involving proprietary software of some kind.  Certain diehards might scoff that, if some software only exists in proprietary form, it’s inherently evil and you must build a free/libre version. But such ideals are rarely achievable when your needs as a new parent and business owner outweigh most others.

As I pondered my motives, it became clear to me that controlling my data was more important to me than controlling the tools.

The next move

For years on Android, I used CalDav and CardDav syncing tools, which were proprietary plugins that presented calendar and contact “providers” to the OS.  These worked great, but finding equivalent staples on Linux was somewhat harder.  The time had arrived when I needed desktop access to calendar, task and contact management, that wasn’t based in an Office365 tenancy.

The right move here was to set up Nextcloud. On my small personal hosting box at DigitalOcean [discount referral link], I set up a virtual server to run Nextcloud.  Nextcloud provides calendar, tasks and contact databases that are conveniently accessible through CardDav & CalDav.

As I had to work on a Mac in order to test websites in Safari (which accounted for at least 9% of traffic, and often more), it was useful to have syncing of this data there too.  And this, unlike some of my earlier grumpiness with all things Mac, was actually a pleasant surprise: macOS actually had great support for CalDav and CardDav.

Conclusion

Account set-up in iOS
Setting up access to other services is a cinch in iOS.

Do I get the solution I need? Yes. Does it sync well? Yes. Am I happier? Yes.

Not only that, but the downside of Orgmode syncing was that it worked best if restricted to two-way communications. If you added a third or fourth client and tried syncing between all of them, it would quickly become a clusterfunk.

Is Apple the enemy?  Well, probably. But better the devil you know, sometimes. Due to the ease of synchronisation with tasks, contacts and calendar in macOS, I slowly warmed up to the idea of replacing my ageing Samsung Galaxy Note 4 with an iPhone. So I did.  And arguably, for this requirement, it was a good choice.

Does this mean I’m no longer a Linux guy? Oh no, not at all. I still have my ThinkPad T420S, which was a side-grade replacement for my chunky T420. I use it every day in my work as a Senior Systems Administrator, for one of the UK’s top universities. I still use Emacs and Orgmode as a daily driver for tasks and coding.

But at home, my wife and I share a calendar and contact list across Android and iOS, thanks to the support of industry standard protocols.

Controlling where the data is has served us pretty well.

Free software such as Linux is great at many things, including keeping your data very safe.  That is, if you are in relative control of it yourself.

Nautilus window open in GNOME.
Transferring sensitive files from one machine to another – offline, via USB stick.

Linux is also used by the likes of Google, Facebook, et al., not to mention most western governments.  In fact, its flexibility, suitability and cost-effectiveness means it’s pretty much there, in most pieces of consumer electronic equipment, plus any networking kit employed in telephone exchanges and data centres, through to the end points – the receiving servers which constitute “the cloud”.

Its use and application is rich and strange: sometimes in your interests, and often, arguably, not so.  But whether you’re a Linux/UNIX, Windows or Mac user, taking care of your own data is vital for a life of value!

Making your digital life private, again

Is it possible to retract data that you previously opted to store online, and be confident that cloud service providers no longer keep it stashed somewhere?  There are two responses to this:

  • “yes”
  • “no”

Let’s assume for a moment that “yes” is, by far, the prevailing truth.  “Yes”, data which I previously uploaded was properly deleted when I deleted it, and an online service provider no longer has any copy, nor any meta data about my data (ok, I’m laughing now).

“there are many ways in which you can protect your data, and protect your privacy”

Many of us have done it: uploaded photos to Google Photos, posted images or event information to Facebook, shared our location on Twitter, set up an account on … well, the list goes on.   But forgetting the “privacy” policy of such entities, just for a second (well, ok then – it’s not that easy to put aside “We store data for as long as it is necessary to provide products and services to you and others”, but even so!!), there are many ways in which you can protect your data, and protect your privacy.  It starts with a little effort and time.

First things, first: get a backup routine!

Rome wasn’t built in a day, and neither is your data security.  For example, consider the following:

  • Is any of your personal data stored on company equipment?
  • Do you absolutely know, hand on heart, that your data is backed up?
    • Did you go ahead and do that yourself?
    • Did someone sign a certificate and say, in no uncertain terms, that they did that on your behalf?
    • When?
  • When did you last audit your data?

A friend of mine recently lost years of pristine digital photos due to a failure of company equipment (“the company laptop”) and because he hadn’t backed them up to a secondary device – even though he had one of sufficient capacity in his possession!

Don’t let this be you!  Get a routine in place for backing up. Even if it’s only monthly, usually cameras and phones have enough capacity to store a month’s worth of shots.

Designate somewhere safe for your backup!

A safe location can be anywhere.  You don’t have to get a fireproof safe – although I’m not saying don’t!  But if you backup your personal data at home, try not to keep your backup at home.  A USB drive costs so little these days, that it’s the perfect medium for backing up photos and then taking it to work and locking in your desk drawer.

Encrypting your data is always a good idea for a removable storage device, provided you can easily remember a strong password.  Although the ease of managing encrypted removable storage varies between operating systems (note, it is very easy to encrypt data on GNU/Linux).

Test restoring from your backup and backup again!

A backup is no good if you can’t restore files from it.  Luckily, with a simple backup process you can easily monitor and validate that your backups have occurred successfully.  If you are confident that your system backups work ok, do another one.  Then store.  Wash, rinse, repeat.

How does this keep my data private?

By setting a rule for yourself to back-up your own data, you won’t become so dependent on cloud services for backing up your photos.

Common objections to keeping data off the cloud include the oft-argued (but ill-conceived) notion that it’s free of cost.  Let’s just examine this for a brief moment:

  • Data centres cost hundreds of thousands, to millions of £/$/€ to build
  • Running costs are tens to hundreds of thousands of £/$/€ each month
  • They must be staffed, too – requiring monthly salaries
  • If everyone is uploading for free, how can it pay for itself?
  • There must be an end-purpose: the end does not justify the means!

The value of your “free” data storage is in the metadata that is stored with it.  Tied to your user account (that same user account you might use to log in to other services, signifying your activity at other times even when not using the primary service…) is data – in the form of metadata – that describes it quite clearly.

What photo metadata tells my cloud provider about me

That photo which was kindly synced to your cloud provider’s account will contain data, like:

  • Where you were (where you live, work, visit, or where friends, family live, work, etc)
  • What local time it was (when you may not be working, placing you into a social demographic)
  • What equipment you were using (which brand you like to buy)
  • What network you were using (who you are a customer of)
  • What the weather was like at the time of the photo
  • Who you were with from the faces of people you were with & photographed … thus registering where they were at that time too (thanks to facial recognition technology and perhaps against their will)
  • Due to prominent colouring in the photo, whether you were inside or outside
  • … and much more.

When free is not free

If I am a massive indexing engine and I start aggregating and analysing these data, I will be able to determine some interesting trends:

  • How many people use my service in an area/region/country
  • How many people who use the service were in a particular area/region/country at a specific time
  • How many of those use Camera brand “B” or Phone brand “A”
  • How many faces I recognise (people who have opted in to facial recognition)
    • Who is in whose “networks” and extended networks (friends of friends)
  • How many faces I don’t recognise (potential targets for acquisition – new users)
  • How many people like being outdoors on a bright, dry day
  • And how many don’t
  • Whether you like being outdoors … or not
  • Who you like being with during those conditions
  • What you might be doing at that time, on that type of day, in those conditions, with those people, while using your “brand X” device.

we are now at a stage where it is easier to get a phone, and rely on Facebook for photo storage

Some people I know seem apathetic towards online security, and yet suspicious towards cloud service provider’s intentions too.  Perhaps we are now at a stage where it is easier to get a phone, and rely on Facebook for photo storage, than to “bother” seeking alternatives.  “The answer is not readily to hand, so let’s move on.”

Living a life less ordinary

The problem with systems is that they need parameters.  Do a search on something, somewhere, and you’ll be sure to see ads and sponsored links of that thing, somewhere else.  This is, and has been for a while, the new internet “norm”.

Breaking out of this “think, search (hunger); feed (consume with contextual data)” lifestyle has been described as the “search bubble”.  A self-fulfilling data management and presentation matrix based on your lifestyle habits.

By adopting a simple routine such as taking care of your own data and not subscribing religiously to online services, it’s possible to find not only more sanctity in life’s unique moments, but also more richness from the due consideration of others.  Where people know you a little less, and are curious to know you a little more.

I recently came across the dreaded owncloud login loop. This surprised
me a little, as I hadn’t performed a software upgrade or otherwise
changed any configuration parameters for a while.

So why the change?

One lesson I have learned long and hard through developing web sites and
testing, is that there are two components which are equally
important: program code and data. Never assume there is
something wrong with your code; your live data (or test data) could be
equally at fault, causing your application to slip up.

In the case of ownCloud, I found that my hosting environment had reached
its quota. Although ownCloud could create session files in /tmp, it
couldn’t write data to them. Perhaps the code should have handled this
more gracefully, but it’s safe to assume that a cloud environment
has hard disk space in order to save its files. That’s what it’s
there for, after all.

So here’s a quick, work-in-progress checklist to ensure your ownCloud installation has the
best chance of working correctly:

  • PHP Sessions should be enabled
  • session.save_path in php.ini should point to a valid (writable)
    filesystem location
  • Storage space on hosting environment should be ample

More to follow when I have further issues..!