
Ask HN: I want to share files from the screen lock of my phone - rdmreader3319
I&#x27;m living in a country where I have to show documents to policemen because they restrict movements because of the flu COVID19. The easiest way is to generate a PDF from a state website.<p>I&#x27;m doing the same thing when I go to the cinema or when I take the train: I show or give my phone to allow the entitled person to check a PDF or a barcode that proves I am allowed to be here.<p>When I do that my phone is unlocked.<p>Police, robbers can steal my unlocked phone when I do that.<p>Stupid joke but if Julian Assange needs to show a barcode when he goes to the cinema, he needs to present his unlocked phone to a stranger.<p>I&#x27;m not Assange, but today I felt very stupid when a city policeman (not a state policeman) asked me for my document when I was in the street with my wife and kids. I didn&#x27;t trust him because he was obviously a city security guard and not a policeman, I asked if he had the authorization to perform this check, but in the end I gave him my unlocked phone to allow him to check my document (everything was OK according to the law).<p>Conclusion: I need an app to share only some selected files from the screen lock.<p>When I take the train, I need to &quot;share&quot; for some hours my traveling documents to this app, it will allow me to pass the barcode scanners without unlocking my phone.<p>I think the HN people might consider this coding opportunity.
======
Nextgrid
Does the file have to be generated on the fly, or does it last for a
reasonable amount of time? In the latter case wouldn't a printed copy work, or
just setting your lock screen background to a screenshot of the document
zoomed in on the barcode.

Alternatively, on iOS, "Guided Access" can be used to lock the phone to a
particular app (let's say the browser) and even prevent certain parts of the
UI from being tappable.

You can bring up the document, activated Guided Access (it has its own
separate passcode to disable) and then hand the phone over. From there they
can either remain in the constrained app, or if they restart the device
they'll get the standard system passcode before they can proceed further so
it's fairly safe to prevent the device from being misused.

------
eigen-vector
If you're using Android you should be able to use user-profiles. You can
create a profile with limited things in it, one of which being web access to
generate this proof.

~~~
rdmreader3319
It's not convenient but it's a nice workaround. I'll do that before mastering
Android Studio !

~~~
battery_cowboy
It doesn't prevent messing with the one app, but Android has a "screen
pinning" function that locks the screen to the current app and can require a
password to unlock. I use it for showing my insurance documents to police.

