Lurker News
I needed a security camera inside my house, one that would send motion notifications to my smartphone and would allow me to livestream remotely. However, I could not find one that I could trust due to privacy concerns. Many of them upload the plaintext of videos to their servers and none is fully open-source as far as I know. Therefore, I decided to use my spare time to build one from scratch. Called Privastead (as in Private Homestead), it uses OpenMLS for end-to-end encryption (between the camera local hub and the smartphone) and is mostly implemented in Rust (except for part of the Android app that is implemented in Kotlin). The system is functional now and I've been using it in my own house for the past couple of weeks.

Based on some of the discussions I've seen online, it seems like there are other users who are also concerned with the privacy implications of home security cameras. Therefore, I decided to open source my solution for everyone to use. If you need a privacy-preserving home security camera, please give it a try and provide feedback. Note that trying out the system requires you to have a supported IP camera, a local machine connected to the IP camera, a server, and an Android smartphone. I have put together detailed instructions on setting up the system, which I hope makes it easier for others to get the system up and running.
In addition, consider contributing to the project. The prototype currently has a lot of limitations: mainly that it has only been tested with one IP camera, only allows the use of one camera, and only supports Android. I'll continue to improve the prototype as time permits, but progress will be much faster if there are other contributors as well.

Comments (165) 36 threads

Earlier comments
EthicalSimilar2 replies#
Did you look into Scrypted? It is OSS. With HomeKit (which is how I use it) it is also E2EE. I’m not sure if their app is E2EE though, I only use HomeKit.

It’s pretty good and has an extensive ecosystem. The dev can be a bit… feisty though.
It’s very performant and easy to setup. I don’t use the NVR features as I already have an NVR, I essentially just use it for HomeKit integration of my cameras + doorbell.
https://github.com/koush/scrypted

amluto1 reply#
> It is OSS.

Barely. A lot of functionality is gated behind the NVR plugin, which is closed-source and fairly expensive.
> easy to setup
In my experience, it’s easy to set up. But it’s extremely configurable in all the wrong ways and quite difficult to configure in the ways that one might actually want to configure. And the front end is not fantastic IMO: event filtering is extremely weak and scrubbing is bizarre.

corytheboyd1 reply#
> But it’s extremely configurable in all the wrong ways

Damn that feels exactly like my experience with Zoneminder. I’m sure it is decent software under the hood, but the UX is downright hostile to anyone who just wants to get IP cameras to do very basic motion detection to record some full resolution footage, which feels like the major, obvious use case that should be optimized for.
I am thankful for OSS existing in this realm, but why do so many solutions make the same mistakes? Am I crazy in thinking that a good out of the box experience is important? Is some critical part of the formula locked behind private walls? Something else? Genuinely curious.

amluto#
I suspect there’s a tendency by the kind of developers who make fancy open source projects to expose all the awesome nerdy power of their software. Have three different motion detectors? Expose all of them! Make them plugins! Have “extensions”! Have components provide “things!” Make a UI for all of that! It’s especially nifty when the UI looks just like the code structure.

But making a good UI for defining object detection zones is hard, so the very first thing that works at all sticks. Or, once you’ve carefully optimized by using the camera’s built in motion detection and having all the streams you could want, supporting software motion detection is an afterthought, and making it configurable in any useful manner is even more of an afterthought. After all, all the cameras you actually use personally have built in detection that works well and also have so many built-in RTSP streams that you never actually had to optimize for the experience of using a camera with a single stream, a somewhat defective implementation of ONVIF, and entirely unusable motion detection. So you make it work, but only using plugins and extensions, and it never becomes pleasant.

arrdalan1 reply#
I'm not familiar with Scrypted unfortunately. But thanks for the pointer. I'll have to study it to understand its security and privacy implications. I skimmed the docs very quickly but couldn't find info on their use of encryption.

About HomeKit: yes, HomeKit uses iCloud end-to-end encryption (https://support.apple.com/en-us/102651) and is certainly superior to those systems that don't use encryption at all or just use encryption between the device and their servers. But Privastead has two advantages:
1) Privastead uses MLS for end-to-end encryption, which provides forward secrecy and post-compromise security. iCloud's end-to-end encryption does not. So what does that mean? This is from the link I included earlier:
"If you lose access to your account, only you can recover this data, using your device passcode or password, recovery contact, or recovery key."
If an attacker manages to access your password, recovery key, etc., they'll be able to decrypt all your videos (assuming they have recorded all your encrypted videos). Such an attack is not possible in MLS. Similar to the Signal protocol, MLS uses double ratchet and there is not a single password, recovery code, key, etc. that can decrypt everything.
2) The HomeKit framework and iCloud end-to-end encryption are not fully open source as far as I know. Therefore, we simply have to trust what Apple says about their security and privacy implications. That might be okay for some users, but not others. Privastead is and intends to remain fully open source. IMO, being open source is a critical component of any security/privacy solution that would like to gain users' trust.

cvwright1 reply#
I’m not sure that 1) is such a win for MLS here.

If I lose my phone, I want to get all my security footage back by entering my passphrase etc on my new phone.
In other words, I want the “encrypted cloud storage” security model from [1], not the encrypted messaging security model from Signal etc.
[1] https://eprint.iacr.org/2024/989

arrdalan#
Interesting. I think the usage model provided by Privastead is reliable enough (at least for me). I have access to my videos on my phone. If losing the phone is a concern (which should be rare), we can easily add a feature that keeps a copy of the files in the hub too.
modeless4 replies#
I've been wishing for a self hosted alternative to cloud cameras. My house was recently robbed and it was incredibly frustrating to know that criminals were literally in my house but not be able to see them due to the general crappiness of modern big tech software.

Seems silly to pay to upload all my video of my own house to who knows where and struggle to download it back with absurdly sluggish proprietary software when I have perfectly good computers here already. I should be able to check my cameras without waiting 10-30 seconds for loading spinners and I should be able to scrub through time instantly instead of waiting for interminable loading every time I touch the seek control.
What camera hardware are people using for custom setups? Is there anything out there that is wireless but with high quality/security firmware and reasonably priced?

mattlondon1 reply#
Ubiquiti cameras store the data on-prem.

Not open source, and not the cheapest (but not absurd either). App is acceptable.

Tempest19811 reply#
I read elsewhere that people are upset since Ubiquiti now requires using Unifi hub, at least for initial configuration. Maybe others do too?
mattlondon#
I think the hub thing is where the local storage is? I don't know if they are just open RTSP things or not that you could use with any random NVR?

I have unifi WiFi APs so have all the rest of the hub/controller anyway and trialled one camera but ultimately opted for Nest cameras instead.

9dev1 reply#
So you did have a cloud camera system in place but it didn’t record them, or you don’t have one because all available options are shitty?
modeless1 reply#
I do (Nest), and it did record them, but the shitty app made it really hard to see what was happening. Takes forever for the app to load, and it can't show all the cameras at once, and tapping into each camera shows another loading spinner, and then seeking through time is frustratingly slow and imprecise. Then there's the split between old cameras in one app and new cameras in another because Google can't be bothered to update old cameras to work with the new app (which is not any better than the old one anyway, worse if anything). It took minutes longer than necessary to get the full picture of what was happening, and when criminals are rifling through your stuff every second matters. Then after the fact it was a huge pain to get the recordings in a form I could archive and share, and there's time pressure because the recordings disappear after just a few days unless manually archived.

OTOH our alarm system (Ring) performed very well.

wkat4242#
Yeah my ring alarm worked well too when my place was broken into. It scared them off, they broke down the door but didn't actually come inside.

Unfortunately that prompted to police to be less than helpful (they considered it vandalism instead of a burglary and didn't even take prints). And because they didn't enter the house my cameras didn't see their faces so I couldn't try to track them down on my own either. But at least my stuff was ok.

wkat42421 reply#
I absolutely hate cloud solutions but in this case there's a big benefit in that the robbers can't steal or smash your servers.

They can do that to your networking gear though but by then hopefully their image has already made it to the cloud.

modeless#
In general I wouldn't expect random street criminals to be able to specifically locate and identify and properly disable a nondescript server in a closet in the middle of a break-in. They're frantically looking for cash and jewelry and portable commodity electronics and firearms. Stuff they can pocket and scram and easily use or fence later.
9x391 reply#
If you insist on 'secure' firmware, you're fighting uphill and probably going to be disappointed with the ecosystem out there. Tunnel back to your home network to access cams if that worries you.

I recommend either Ubiquiti or Reolink cameras, both are power-over-Ethernet. Both offer an app that allows connecting back to your equipment. UI will require their Protect software running on one of their local platforms in your house with storage on 1 or more disk drives, while Reolink offers direct storage on microSD on the camera itself, capped at 256GB.

modeless2 replies#
Unfortunately my house is not wired for Ethernet and it's a rental so I can't install it. Wireless is a must and security is obviously important for wireless. But I think you are correct that I will be disappointed by what's out there.
9x39#
Unfortunate. Reolink even has wireless cameras, but they will require a DC input, so you'd need an outdoor electrical outlet if you can't drill any holes and sneak either a power or UTP Ethernet cable.

Given the strict physical requirements, you might be looking at battery-backed wireless cameras of the type often found on Amazon, but afaik they will never offer the local storage or control you want.
I will say that surprising things can be accomplished with small drilled holes and a fishtape. Your risk tolerance and how nice the rental are obviously very important factors.

kdmtctl1 reply#
I used a Reolink Argus with a battery and Wi-Fi connection. The one I used is probably EOL now, but a quick look at the site shows even solar chargeable options. So, it is possible.

Continue this thread — 1 reply

tills132 replies#
If you're like me and you want something that Just Works -- ubiquiti's offering is fully local and has all the features you'd want including alerts, ml detection (on some first party cameras), app, timeline, etc. They recently started allowing third party cameras, too, so all you need is a Cloud Gateway (USG Ultra is $150) and you're good to go.
tuchsen#
The last time I upgraded my networking setup (just as the pandemic started) I went with Ubiquiti, shortly after (before?) they started default forcing you to sign up for their cloud service to use the router, you can switch it to a locally operated mode after you sign up but they bury it in the options. Their networking equipment works great, don't get me wrong, but they don't open source anything. I keep waiting for the full rug pull when sales start to slow because everything they release is rock solid and everything I have is "good enough." I don't feel the need to upgrade for as long as the rug pull doesn't happen.

I am super grateful people are starting to work on open source solutions to this stuff :).

sneak1 reply#
It is reasonable to assume that Ubiquiti has remote access to your fully local data, given that they run the auth server and also push automatically installed updates.
tills131 reply#
> they run the auth server

I don't think this is true unless you are logging into your router using the ui.com console. Logging in to my UDM POSTs to the local address and works without a WAN connection.
> also push automatically installed updates
I suppose if you've enabled them.

sneak1 reply#
Autoupdate is on by default.

Even for local auth, the auth database comes from the cloud service.

Continue this thread — 1 reply

dylan6041 reply#
"Privastead uses the Google Firebase Cloud Messaging (FCM)"

I'm am totally unfamiliar with this, but what level of concern that theGoogs pulls the plug on this service about the time you gain traction?

arrdalan1 reply#
I'm not too concerned with that. As far as I know, almost all Android apps that need to send notifications to the device use FCM. If Google pulls the plug on it, many apps will stop working as intended.
arrdalan2 replies#
I did not, but I will. I would just point out that Privastead assumes the the push notification infrastructure is untrusted anyway.

Continue this thread — 2 replies

All comments shown.