Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fingerprint Support #11

Closed
ldelossa opened this issue Jun 6, 2022 · 10 comments
Closed

Fingerprint Support #11

ldelossa opened this issue Jun 6, 2022 · 10 comments

Comments

@ldelossa
Copy link
Contributor

ldelossa commented Jun 6, 2022

Hey there.
GTKLock looks awesome. However, would it be possible to support libfprint finger print? Ideally, this setup works very nicely for swaylock: swaywm/swaylock#61 (comment)

@jovanlanik
Copy link
Owner

AFAIK the libfprint support is a PAM module and would probably work in gtklock too.
Try adding the same lines to /etc/pam.d/gtklock.

@ldelossa
Copy link
Contributor Author

ldelossa commented Jun 7, 2022

Ah, i see, no modifications necessary to gtklock code? Ill give this a go.

If one wanted to add UI elements which indicate fingerprint, they can be written as a module?

@jovanlanik
Copy link
Owner

I'm working on a solution to display messages and errors from PAM modules in the UI so there will be some indication.
But it will be only text, if you wanted an icon then a module that reads the message and adds an appropriate icon could work.
The module API is still in the early stages and will be improved down the line. So far the only module is useless, I'll consider making some better examples.

@ldelossa
Copy link
Contributor Author

ldelossa commented Jun 8, 2022

Thanks, also gtklock works exactly like swaylock when I use the same PAM config. 👍

@jovanlanik
Copy link
Owner

jovanlanik commented Jun 8, 2022

Glad it works for now, I'll close this issue when I push the UI messages...

EDIT: Also the documentation should be updated...

@jovanlanik
Copy link
Owner

I pushed the changes to the message branch and tested using the pam_echo module.
Could you test with the pam_fprintd module and see if you get any messages?

@ldelossa
Copy link
Contributor Author

ldelossa commented Jun 8, 2022

@jovanlanik just gave it a try. Get a seg fault.

#0  0x0000000000405f62 in window_setup_messages ()
#1  0x00000000004056bf in window_setup ()
#2  0x0000000000405485 in window_configure ()
#3  0x000000000040513e in reload_outputs ()
#4  0x0000000000404e9f in setup_layer_shell ()
#5  0x0000000000404e42 in activate ()
#6  0x00007ffff7125db0 in g_closure_invoke (closure=0x5307c0, return_value=0x0, n_param_values=1, param_values=0x7fffffffd700, invocation_hint=0x7fffffffd680) at ../gobject/gclosure.c:830
#7  0x00007ffff71524d6 in signal_emit_unlocked_R.isra.0
    (node=node@entry=0x5749e0, detail=detail@entry=0, instance=instance@entry=0x4a9210, emission_return=emission_return@entry=0x0, instance_and_params=instance_and_params@entry=0x7fffffffd700) at ../gobject/gsignal.c:3743
#8  0x00007ffff7142a2e in g_signal_emit_valist (instance=<optimized out>, signal_id=<optimized out>, detail=<optimized out>, var_args=var_args@entry=0x7fffffffd8b0)
    at ../gobject/gsignal.c:3496
#9  0x00007ffff7142cb3 in g_signal_emit (instance=instance@entry=0x4a9210, signal_id=<optimized out>, detail=detail@entry=0) at ../gobject/gsignal.c:3553
#10 0x00007ffff724d653 in g_application_activate (application=application@entry=0x4a9210) at ../gio/gapplication.c:2308
#11 0x00007ffff724f788 in g_application_real_local_command_line (application=0x4a9210, arguments=0x7fffffffd9f8, exit_status=0x7fffffffd9f4) at ../gio/gapplication.c:1144
#12 0x00007ffff724f918 in g_application_run (application=0x4a9210, argc=<optimized out>, argv=0x7fffffffdb98) at ../gio/gapplication.c:2538
#13 0x0000000000404c86 in main ()

gdb backtrace above.

@jovanlanik
Copy link
Owner

@ldelossa Can you try it again? I did some more work on the message branch.

@ldelossa
Copy link
Contributor Author

Aha! that is pretty slick!

My only suggestion is, the entire UI seems to "shift up" when a message is displayed. This is subjective, but it maybe "smoother" to have them not shift the text around.

But overall, this is very dope.

@jovanlanik
Copy link
Owner

Well, the content of the window is supposed to be centered. Maybe I'll look into an animation to smooth it out.
Thank you for testing, I'll merge to master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants