GNOME Bugzilla – Bug 484976
Private Memory Lock error on systems that restrict use of mlock()
Last modified: 2019-02-22 11:47:20 UTC
Please describe the problem: On Solaris it is not possible to use mlock() to lock memory into physical RAM due to it's impact on system resource, without additional privileges. A regular user doesn't have this privilege by default, and this results in the message: couldn't lock 16384 bytes of private memory: Not owner ** Message: couldn't allocate secure memory to keep passwords and or keys from being written to the disk While this is true, this message should really be a debug message and not output all of the time when an application is run. Steps to reproduce: Run any application (e.g. pidgin) that uses gnome-keyring on Solaris, or a system that restricts the use of mlock. Actual results: An error message is output. Expected results: Nothing, unless debug is enabled. The s/w is behaving as expected and as such should not complain. Does this happen every time? Yes Other information:
Well it is not not really behaving as expected. Part of the expectation of gnome-keyring is to keep your passwords secure, and because of the OS it is not able to do that. Is there another method on Solaris that we can obtain non-pageable memory, or perhaps another method for storing things securely in memory? gnome-keyring needs very little memory for these purposes. Allowing say, 16K of non-pageable memory per user would suffice. Hiding the problem, in my opinion, isn't an optimal solution. This message is not seen by GUI users, but alerts administrators, developers and/or power users to the possible issue, until such a time as it is resolved on the OS or distribution in question.
Ah, I see what you meant. Yes you're right. It seems dumb to print this message for applications, although for the daemon it makes sense. Committed patch to the gnome-2-20 branch. If you have a chance, please build it and let me know if this fixes your problem. Fix will be included in 2.20.3.
Whoops I meant 'included in 2.20.2'.