{"id":18678804,"url":"https://github.com/jpodivin/facesnap","last_synced_at":"2026-04-27T16:31:09.415Z","repository":{"id":43719018,"uuid":"410209225","full_name":"jpodivin/facesnap","owner":"jpodivin","description":"Open lid, take a pick","archived":false,"fork":false,"pushed_at":"2022-07-06T08:23:43.000Z","size":74,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-18T15:09:46.182Z","etag":null,"topics":["python","security","utility"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jpodivin.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-09-25T07:43:22.000Z","updated_at":"2021-12-28T15:19:55.000Z","dependencies_parsed_at":"2022-08-25T21:50:27.046Z","dependency_job_id":null,"html_url":"https://github.com/jpodivin/facesnap","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/jpodivin/facesnap","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpodivin%2Ffacesnap","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpodivin%2Ffacesnap/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpodivin%2Ffacesnap/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpodivin%2Ffacesnap/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jpodivin","download_url":"https://codeload.github.com/jpodivin/facesnap/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpodivin%2Ffacesnap/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32345802,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-26T23:26:28.701Z","status":"online","status_checked_at":"2026-04-27T02:00:06.769Z","response_time":128,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["python","security","utility"],"created_at":"2024-11-07T09:41:27.828Z","updated_at":"2026-04-27T16:31:09.394Z","avatar_url":"https://github.com/jpodivin.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# facesnap: Open lid, take a pick\n\n![facesnap logo](https://raw.githubusercontent.com/jpodivin/facesnap/master/logo.png)\n\n![build](https://github.com/jpodivin/facesnap/actions/workflows/main.yml/badge.svg)\n![pep8](https://github.com/jpodivin/facesnap/actions/workflows/flake8.yml/badge.svg)\n\nEver wondered if anyone was touching your laptop while you were away?\nIf you are like me, you did, and you have probably rigged some sort script\nto make sure you know who it was. \n\nI've recreated the one I used to run in python and turned it into a proper service.\nOnce installed and running, the facesnap will take 3 pictures,\nwhenever someone opens a lid of your laptop and store them in the `~/facesnaps` directory.\n\nThe delay is set to 1 sec, to increase likelyhood that camera is facing the persons\nface, and not something else. \n\n## Installation\n\n### Prerequisites\nFacesnap listens to system messages using pydbus and PyGObject.\nUnfortunately, installing PyGObject takes a bit more than a rootless pip. \nFortunately, the folks behind PyGObject have provided simple [instructions](https://pygobject.readthedocs.io/en/latest/getting_started.html) compatible with all major distros.\n\n### Installing facesnap\nIn order to get facesnap up and running as service for the root user you need to install the script itself and the unit file to register it with systemd.\nEither with sudo, which is easier, but not recommended on the security grounds.\nThe upside of this approach, if you want to call it that way,\nis that pics will get stored in home of the `root`.\n\nAnd will thus remain only accesible to people with root access.  \n\n```\nsudo pip install .\nsudo ./installservice.sh\n```\n\nOr you can install facesnap as a normal user, which will require couple of tweeks\nto the `facesnap.service` file. \n\nFor one the `ExecStart` key must be set to place where you have installed the facesnap.py script. You should also add `User` and `Group` keys.\n\nNo matter the method, you will need to reload the units and start the service for the changes to take effect.\n\n```\nsudo systemctl daemon-reload\nsudo systemctl enable facesnap.service\nsudo systemctl start facesnap.service\n```\n\n## Adjust the behavior\n\nI would encourage you to survey the script before installation,\nbut I'm sure you are doing it already. \n\nSo I'll instead suggest that you should consider if the settings are to your liking. For example you might want the images to be stored elswhere, or for them to be taken after shorter delay.\n\nIf you are fancy, you can insert a face reckognition algorithm to only store pictures\nof actual faces, or to discern your own face, from the faces of others.\nThe opencv is already in requirements, and not just because of the friendly API.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjpodivin%2Ffacesnap","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjpodivin%2Ffacesnap","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjpodivin%2Ffacesnap/lists"}