Bug 181870 - Key quota handling incorrect in allocation
Summary: Key quota handling incorrect in allocation
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: kernel
Version: 4.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
: ---
Assignee: David Howells
QA Contact: Brian Brock
URL:
Whiteboard:
Depends On:
Blocks: 181409
TreeView+ depends on / blocked
 
Reported: 2006-02-17 11:16 UTC by David Howells
Modified: 2007-11-30 22:07 UTC (History)
0 users

Fixed In Version: RHSA-2006-0575
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2006-08-10 22:20:26 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Fix key quota detection in key allocation (462 bytes, patch)
2006-02-17 11:16 UTC, David Howells
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2006:0575 0 normal SHIPPED_LIVE Important: Updated kernel packages available for Red Hat Enterprise Linux 4 Update 4 2006-08-10 04:00:00 UTC

Description David Howells 2006-02-17 11:16:15 UTC
Description of problem:  
  
The key quota detection in key allocation only fails if *both* quotas are 
exceeded (there's a total space quota and a key count quota). 
  
Version-Release number of selected component (if applicable):  
 
 
How reproducible:  
  
100% 
  
Steps to Reproduce:  
1. key session - 
2. for ((i=1; i<101; i++)); do keyctl add user $i "a" @s; done 
3. cat /proc/key-users 
    
Actual results:  
 
Allocates all the keys successfully and attaches them to the session keyring. 
It can then be seen in step 3 that the key count quota has been exceeded. 
  
NOTE! This assumes that other pre-existing keys owned by this user won't 
already have shoved the key space quota into excess. 
 
Expected results:  
 
The excess key allocations should give a "Disk quota exceeded" error, 
and /proc/key-users should show that the number of keys allocated to that user 
maxes out at the quota. 
  
Additional info:

Comment 1 David Howells 2006-02-17 11:16:15 UTC
Created attachment 124807 [details]
Fix key quota detection in key allocation

Comment 6 Red Hat Bugzilla 2006-08-10 22:20:26 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2006-0575.html



Note You need to log in before you can comment on or make changes to this bug.