Re: dynamic memory automatically zero'd

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08/06/2010 07:44 AM, Stefan Schulze Frielinghaus wrote:
> Hi all,
>
> if you allocate memory, e.g. via malloc(3), then it is automatically set
> to zero. This is actually a security feature quite common nowadays. I
> would like to know when this feature has made it into Fedora or in RHEL.
> Is this a mandatory feature of some security policy as e.g. the Common
> Criteria? I couldn't find much information about this. Therefore, any
> pointers, hints and so on are welcomed!

calloc() is the call you want to make.  The ANSI standard makes no
guarantees about the contents of the memory you get with malloc().  In
fact, calloc() was created for that precise reason.
----------------------------------------------------------------------
- Rick Stevens, Systems Engineer, C2 Hosting          ricks@xxxxxxxx -
- AIM/Skype: therps2        ICQ: 22643734            Yahoo: origrps2 -
-                                                                    -
-     There are only 10 kinds of people in the world -- those who    -
-                 understand binary and those who don't              -
----------------------------------------------------------------------
-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux