Google sign-in or SSO, or OAuth or something else

hallo everybody.
I hope this is not a duplicate of many other post, but I didn’t fully understand those tecnologies.

I would like to share some photos, using my friends’ email (i.e. bob@gmail.com , tom@yahoo.it) and I would like them to access that private content by authenticating themself against gmail.com or yahoo.it using their own password.

one more feature: when Bob logs in, he could see a list with all the contents he can access.

one more feature: if Bob has a local account on my Nextcloud server, he can log in with google credentials.

Is it possible?
Do I need some app to be installed?

Thanks in advance for useful for information,
Jack