4 More Discussions You Might Find Interesting
1. Red Hat
If i want to build. Red Hat Enterprice server.
And run top of that windows domain virtualization or maybe couple of them top one one Red Hat server hadware.
If you had like 2500€ budjet what would you buy?.
Or obtionally install red hat and virtualisation on one machine and one windows domain... (3 Replies)
Discussion started by: ezegiel1984
3 Replies
2. UNIX for Dummies Questions & Answers
Hi, I would like to know what kind of UNIX major investment banks tend to use? I want to try to get a job with one of these places. By major, I mean big companies like Citigroup, JP Morgan Chase, Morgan Stanley, etc. Thanks. (5 Replies)
Discussion started by: rubrubber
5 Replies
3. Cybersecurity
Hello,
Long time ago we used to suffer from relay and users using your own mailservers to spam but thanks god for auth-before-pop.
But now i'm facing small problem with someone which us he is spaning using whatever mailserver with your@email.address.com and when these emails go to unknown... (10 Replies)
Discussion started by: Bashar
10 Replies
4. UNIX for Dummies Questions & Answers
I am having this problem......when I run this script:
print -n "Enter file name to be deleted: "
read answer
if
then
rm $name
else
echo "No such file with the name: $name exists"
fi
I was trying to test my script for errors, and basically when the user had files with the rights: 400,... (1 Reply)
Discussion started by: Makaveli.2003
1 Replies
LEARN ABOUT ULTRIX
mprotect
mprotect(2) System Calls Manual mprotect(2)
Name
mprotect - memory protection control
Syntax
#include <sys/mman.h>
#include <sys/types.h>
int mprotect (addr, len, prot)
caddr_t addr;
int len, prot;
Description
The system call changes the protection of portions of an application program's data memory. Protection is performed on page cluster bound-
aries. The default protection for data memory on process invocation is user READ/WRITE. The addr argument is the beginning address of the
data block and must fall on a page cluster boundary.
The len argument is the length of the data block, in bytes. The length of the block is rounded up to a cluster boundary, and the size of
the block to be protected is returned.
The prot argument is the requested protection for the block of memory. Protection values affect only the user process. Protection values
are defined in <mman.h> as:
/* protections are chosen from these bits, ORed together */
#define PROT_READ 0x1 /* pages can be read */
#define PROT_WRITE 0x2 /* pages can be written */
#define PROT_EXEC 0x4 /* pages can be executed */
Setting the prot argument to zero (0) indicates that the process cannot reference the memory block, without causing a fault.
A protected page faults if the protection is violated, and a SIGBUS signal is issued. If the process has a handler defined for the SIGBUS
signal, the code parameter, described in and is used to pass in the virtual address that faulted.
Restrictions
The page cluster size may change in future versions of ULTRIX. As a result, should be used to determine the correct len argument, and or
should be used to determine the correct addr argument.
If the user handles a SIGBUS signal, the signal handler must either abort the process or correct the condition that caused the protection
fault (SIGBUS). If some corrective action is not taken, an infinite loop results because the faulting instruction is restarted. If the
user permits the default SIGBUS handler to be used, the process aborts if a referenced page causes a fault.
The VAX architecture makes the following implications; PROT_WRITE implies (PROT_WRITE | PROT_READ | PROT_EXEC), and PROT_READ implies
(PROT_READ | PROT_EXEC).
Only the application can change the call's private data space. This means that attempts to change text, shared memory, or stack space
causes a EACCES failure.
Return Values
Upon successful completion, the size of the protected memory block, in bytes, is returned. Otherwise, a value of -1 is returned and errno
is set to indicate the error.
Diagnostics
The call fails under the following conditions:
[EALIGN] The addr argument is not on a cluster boundary.
[EINVAL] The prot argument is not a valid protection mask.
[EACCES] The memory block is not fully contained within private data space.
See Also
getpagesize(2), sbrk(2), sigvec(2), malloc(3), signal(3)
mprotect(2)