Re: [e-users] polkit problem

2022-12-13 Thread Carsten Haitzler
On Tue, 13 Dec 2022 10:22:32 -0500 Conrad Knight  said:

> > From: Carsten Haitzler 
> > so - build e/efl without asan and it'll all work fine. or ... get digging
> > deep, built pam with asan and find out just what on earth is really going
> > on.
> 
> Wow, that is a weird one! At least i know now it's not E. As i haven't
> had any crashes or restarts lately (fingers crossed), i'll just switch
> to a non-asan build.

yeah - use non-asan, unless you have some irritating bug to hunt and you see
often enough to catch it. then rebuild it all with asan and presto. hunt that
bug! :)


-- 
- Codito, ergo sum - "I code, therefore I am" --
Carsten Haitzler - ras...@rasterman.com



___
enlightenment-users mailing list
enlightenment-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-users


Re: [e-users] polkit problem

2022-12-13 Thread Conrad Knight
> From: Carsten Haitzler 
> so - build e/efl without asan and it'll all work fine. or ... get digging 
> deep,
> built pam with asan and find out just what on earth is really going on.

Wow, that is a weird one! At least i know now it's not E. As i haven't
had any crashes or restarts lately (fingers crossed), i'll just switch
to a non-asan build.

-Conrad.
-- 
Shine like thunder
Cry like rain


___
enlightenment-users mailing list
enlightenment-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-users


Re: [e-users] polkit problem

2022-12-13 Thread Carsten Haitzler
On Mon, 12 Dec 2022 12:10:42 -0500 Conrad Knight  said:

so .. all i can say is... everything e passes in to pam is correct. the pam
conversation only asks for a password and e ckpasswd provides it with:

   case PAM_PROMPT_ECHO_OFF:
 reply[replies].resp_retcode = PAM_SUCCESS;
 reply[replies].resp = strdup(ai->pw);

so any pointers passwd in by e are correct. this conversation func ptr was one
thing that could be but it was and is set up right:

typedef struct
{
   const char *user;
   const char *pw;
} Authinfo;
...
   Authinfo ai;
   struct pam_conv conv;
...
   ai.user = user;
   ai.pw = pw;   Authinfo ai;
...
   conv.conv = _conv_cb;
   conv.appdata_ptr = 

   if (pam_start(prof, user, , ) != PAM_SUCCESS) return -1;
   if (pam_set_item(handle, PAM_USER, user) != PAM_SUCCESS) return -1;
   if (pam_set_item(handle, PAM_RHOST, host) != PAM_SUCCESS) return -1;

   pamerr = pam_authenticate(handle, 0);

it's this above function (pam_authenticate) that dies internally if and only if
you build e (specifically e's ckpasswd util) with asan. i can only imagine that
pam does something internally - possibly due to security reasons, to make it
not work with asan. at this point i'd need to build pam and all modules it uses
with gdb debug and possibly asan support to find out more. but all of this
fails because ckpasswd is built with asan enabled. everything e does on its end
in the code (read e_ckpasswd_main.c) is correct here. it's passing in
everything as it should in the way it should. pam barfs somewhere inside -
possibly can't load some module or find some symbol or something and the error
handling is bad as it never expects this to fail and ends up calling a null
address. gnome's polkit tool works because it's not built with asan ... and
it's not using pam directly itself to do the auth checks.

so - build e/efl without asan and it'll all work fine. or ... get digging deep,
built pam with asan and find out just what on earth is really going on.

but ...all is fine without asan. :)

> I'm having a problem with E's polkit module. I was running
> pamac-manager and it asked for authentication. The password dialog box
> popped up, i entered my password, but then got an authentication
> failure error message.
> 
> There's some output in .e-log.log that looks relevant:
> 
> AUTH: POLKIT:
> [3-85675816164cbd241ec6e8b4f92b0e4f-3-a4ac0b07e510e40440dbf83b5e4bcfb8] AUTH:
> UID: [1000] AUTH: readpass...
> AddressSanitizer:DEADLYSIGNAL
> =
> ==99121==ERROR: AddressSanitizer: SEGV on unknown address
> 0x (pc 0x bp 0x7fffdece1aa0 sp 0x7fffd
> ece1228 T0)
> ==99121==Hint: pc points to the zero page.
> ==99121==The signal is caused by a READ memory access.
> ==99121==Hint: address points to the zero page.
> #0 0x0  ()
> #1 0x7fb5b6ceb74b  (/usr/lib/security/pam_unix.so+0x574b)
> 
> AddressSanitizer can not provide additional info.
> SUMMARY: AddressSanitizer: SEGV ()
> ==99121==ABORTING
> 
> If i unload the polkit module and manually start
> polkit-gnome-authentication-agent-1 instead, and then try again,
> everything works: i get a gnome password dialog box instead of an E
> one, i enter my password, and pamac starts its update process.
> 
> I don't know when this problem may have started, as i rarely use
> pamac. Hmm, it just occurred to me that gparted also asks for
> authentication with polkit. Tried running that, and the same thing
> happens. After entering my password, i get an E error dialog telling
> me "Enlightenment was unable to run the application...". And there's
> another, similar message in .e-log.log.
> 
> Any ideas what might be wrong?
> 
> Thanks,
> -Conrad.
> 
> -- 
> Shine like thunder
> Cry like rain
> 
> 
> ___
> enlightenment-users mailing list
> enlightenment-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-users
> 


-- 
- Codito, ergo sum - "I code, therefore I am" --
Carsten Haitzler - ras...@rasterman.com



___
enlightenment-users mailing list
enlightenment-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-users


Re: [e-users] polkit problem

2022-12-13 Thread Carsten Haitzler
On Mon, 12 Dec 2022 12:10:42 -0500 Conrad Knight  said:

> I'm having a problem with E's polkit module. I was running
> pamac-manager and it asked for authentication. The password dialog box
> popped up, i entered my password, but then got an authentication
> failure error message.
> 
> There's some output in .e-log.log that looks relevant:
> 
> AUTH: POLKIT:
> [3-85675816164cbd241ec6e8b4f92b0e4f-3-a4ac0b07e510e40440dbf83b5e4bcfb8] AUTH:
> UID: [1000] AUTH: readpass...
> AddressSanitizer:DEADLYSIGNAL
> =
> ==99121==ERROR: AddressSanitizer: SEGV on unknown address
> 0x (pc 0x bp 0x7fffdece1aa0 sp 0x7fffd
> ece1228 T0)
> ==99121==Hint: pc points to the zero page.
> ==99121==The signal is caused by a READ memory access.
> ==99121==Hint: address points to the zero page.
> #0 0x0  ()
> #1 0x7fb5b6ceb74b  (/usr/lib/security/pam_unix.so+0x574b)
> 
> AddressSanitizer can not provide additional info.
> SUMMARY: AddressSanitizer: SEGV ()
> ==99121==ABORTING
> 
> If i unload the polkit module and manually start
> polkit-gnome-authentication-agent-1 instead, and then try again,
> everything works: i get a gnome password dialog box instead of an E
> one, i enter my password, and pamac starts its update process.
> 
> I don't know when this problem may have started, as i rarely use
> pamac. Hmm, it just occurred to me that gparted also asks for
> authentication with polkit. Tried running that, and the same thing
> happens. After entering my password, i get an E error dialog telling
> me "Enlightenment was unable to run the application...". And there's
> another, similar message in .e-log.log.
> 
> Any ideas what might be wrong?

something seems to be jumping to the NULL address - some function ptr is null
maybe? but this is INSIDE the pam module. (sorry accidentally sent too early).

now i don't have any trace beyond that pam module. i don't know how it's ending
up in this pam module. i don't even know for sure WHAT is ending up there. what
process?

> Thanks,
> -Conrad.
> 
> -- 
> Shine like thunder
> Cry like rain
> 
> 
> ___
> enlightenment-users mailing list
> enlightenment-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-users
> 


-- 
- Codito, ergo sum - "I code, therefore I am" --
Carsten Haitzler - ras...@rasterman.com



___
enlightenment-users mailing list
enlightenment-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-users


Re: [e-users] polkit problem

2022-12-13 Thread Carsten Haitzler
On Mon, 12 Dec 2022 12:10:42 -0500 Conrad Knight  said:

update - i started running gparted as a test. indeed i see:

AUTH: POLKIT:
[2-f82cac0bd4d54babd4e3bab9219a26bc-5-897b2680c1c90cddcf5bb0e281634211] AUTH:
UID: [1000] AUTH: readpass...
AddressSanitizer:DEADLYSIGNAL
=
==22551==ERROR: AddressSanitizer: SEGV on unknown address 0x (pc
0x bp 0x7ffc0a3dc800 sp 0x7ffc0a3dbf88 T0) ==22551==Hint: pc points
to the zero page. ==22551==The signal is caused by a READ memory access.
==22551==Hint: address points to the zero page.
#0 0x0  ()
#1 0x7f64c4e7f74b  (/usr/lib/security/pam_unix.so+0x574b)

AddressSanitizer can not provide additional info.
SUMMARY: AddressSanitizer: SEGV ()
==22551==ABORTING

i suspect it's the e ckpasswd util/tool in e.

> I'm having a problem with E's polkit module. I was running
> pamac-manager and it asked for authentication. The password dialog box
> popped up, i entered my password, but then got an authentication
> failure error message.
> 
> There's some output in .e-log.log that looks relevant:
> 
> AUTH: POLKIT:
> [3-85675816164cbd241ec6e8b4f92b0e4f-3-a4ac0b07e510e40440dbf83b5e4bcfb8] AUTH:
> UID: [1000] AUTH: readpass...
> AddressSanitizer:DEADLYSIGNAL
> =
> ==99121==ERROR: AddressSanitizer: SEGV on unknown address
> 0x (pc 0x bp 0x7fffdece1aa0 sp 0x7fffd
> ece1228 T0)
> ==99121==Hint: pc points to the zero page.
> ==99121==The signal is caused by a READ memory access.
> ==99121==Hint: address points to the zero page.
> #0 0x0  ()
> #1 0x7fb5b6ceb74b  (/usr/lib/security/pam_unix.so+0x574b)
> 
> AddressSanitizer can not provide additional info.
> SUMMARY: AddressSanitizer: SEGV ()
> ==99121==ABORTING
> 
> If i unload the polkit module and manually start
> polkit-gnome-authentication-agent-1 instead, and then try again,
> everything works: i get a gnome password dialog box instead of an E
> one, i enter my password, and pamac starts its update process.
> 
> I don't know when this problem may have started, as i rarely use
> pamac. Hmm, it just occurred to me that gparted also asks for
> authentication with polkit. Tried running that, and the same thing
> happens. After entering my password, i get an E error dialog telling
> me "Enlightenment was unable to run the application...". And there's
> another, similar message in .e-log.log.
> 
> Any ideas what might be wrong?
> 
> Thanks,
> -Conrad.
> 
> -- 
> Shine like thunder
> Cry like rain
> 
> 
> ___
> enlightenment-users mailing list
> enlightenment-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-users
> 


-- 
- Codito, ergo sum - "I code, therefore I am" --
Carsten Haitzler - ras...@rasterman.com



___
enlightenment-users mailing list
enlightenment-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-users


Re: [e-users] polkit problem

2022-12-13 Thread Carsten Haitzler
On Mon, 12 Dec 2022 12:10:42 -0500 Conrad Knight  said:

> I'm having a problem with E's polkit module. I was running
> pamac-manager and it asked for authentication. The password dialog box
> popped up, i entered my password, but then got an authentication
> failure error message.
> 
> There's some output in .e-log.log that looks relevant:
> 
> AUTH: POLKIT:
> [3-85675816164cbd241ec6e8b4f92b0e4f-3-a4ac0b07e510e40440dbf83b5e4bcfb8] AUTH:
> UID: [1000] AUTH: readpass...
> AddressSanitizer:DEADLYSIGNAL
> =
> ==99121==ERROR: AddressSanitizer: SEGV on unknown address
> 0x (pc 0x bp 0x7fffdece1aa0 sp 0x7fffd
> ece1228 T0)
> ==99121==Hint: pc points to the zero page.
> ==99121==The signal is caused by a READ memory access.
> ==99121==Hint: address points to the zero page.
> #0 0x0  ()
> #1 0x7fb5b6ceb74b  (/usr/lib/security/pam_unix.so+0x574b)
> 
> AddressSanitizer can not provide additional info.
> SUMMARY: AddressSanitizer: SEGV ()
> ==99121==ABORTING
> 
> If i unload the polkit module and manually start
> polkit-gnome-authentication-agent-1 instead, and then try again,
> everything works: i get a gnome password dialog box instead of an E
> one, i enter my password, and pamac starts its update process.
> 
> I don't know when this problem may have started, as i rarely use
> pamac. Hmm, it just occurred to me that gparted also asks for
> authentication with polkit. Tried running that, and the same thing
> happens. After entering my password, i get an E error dialog telling
> me "Enlightenment was unable to run the application...". And there's
> another, similar message in .e-log.log.
> 
> Any ideas what might be wrong?

something seems to be jumping to the NULL address - some function ptr is null
maybe? but this is INSID the pam module. 

> Thanks,
> -Conrad.
> 
> -- 
> Shine like thunder
> Cry like rain
> 
> 
> ___
> enlightenment-users mailing list
> enlightenment-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-users
> 


-- 
- Codito, ergo sum - "I code, therefore I am" --
Carsten Haitzler - ras...@rasterman.com



___
enlightenment-users mailing list
enlightenment-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-users