Commit Graph

333 Commits

Author SHA1 Message Date
4lDO2 a7c817d81a WIP: Support setuid/setgid 2022-07-26 21:33:01 +02:00
4lDO2 37cc4e5383 WIP: Add setuid/setgid support. 2022-07-26 21:33:01 +02:00
4lDO2 c95d276af9 Allow POSIX's environ to be set.
Rust's libstd for example uses environ when using the `envs` builder
method for spawning processes, and therefore relibc cannot simply assume
environ will always point to the internal relibc env var Vec.
2022-07-26 21:33:01 +02:00
4lDO2 2186cd1fbd Implement fexec in userspace. 2022-07-26 21:32:56 +02:00
Jeremy Soller 559387cc64 Initial support for x86 32-bit 2022-07-22 16:24:45 -06:00
Jeremy Soller 7f3f2fa105 Add some messages when unimplemented PTE functions are called 2022-04-14 07:52:39 -06:00
Jeremy Soller 8576b99759 Add timeout to futex_wait calls 2022-04-04 20:23:29 -06:00
4lDO2 ebd597f748 Update dependencies for rust 2022-03-18. 2022-03-24 17:12:02 +01:00
Jeremy Soller ec0047c864 Fix redox readlink 2022-03-23 13:47:58 -06:00
Jeremy Soller f63d9cefad Add mlock and friends 2022-03-17 14:03:45 -06:00
Jeremy Soller e90fa3e32f Do not try to open traceme on special PIDs 2021-12-01 09:52:31 -07:00
Jeremy Soller c51aec1af6 Workaround waitpid deadlock by making ptrace state thread local 2021-11-30 21:19:48 -07:00
Jeremy Soller 7a8015eb68 Use r10 instead of rcx for linux pte_clone 2021-11-30 11:34:53 -07:00
Jeremy Soller 66615ef449 Use CLONE_THREAD for linux pte_clone 2021-11-30 11:27:02 -07:00
Jeremy Soller 65bd3ed1e3 Fixes for program_invocation_name and program_invocation_short_name 2021-11-30 10:27:24 -07:00
Jeremy Soller a50d80ee28 Use anonymous fmap 2021-09-22 20:47:18 -06:00
Jeremy Soller ae7cee26a6 Move wctype_t definition to wctype rust header 2021-09-14 20:36:23 -06:00
4lDO2 a388b1ae4d Initialize TLS manually on Redox too. 2021-08-05 11:49:40 +02:00
Jeremy Soller 9f3aa6d4a8 Define wctype_t and wctype 2021-07-19 09:16:56 -06:00
Peter Limkilde Svendsen 9e8cd0bf07 Centralize page size info in platform abstraction 2021-03-24 00:02:39 +01:00
Jeremy Soller 7012c262f0 Use sched_yield when sleeping with msecs == 0 2021-03-16 21:46:24 -06:00
Jeremy Soller e24d27a0b3 Use UTF-8 for redox paths 2021-02-14 14:06:52 -07:00
Jeremy Soller 3c1300e8ec Improvements for aarch64 support 2021-01-11 08:52:20 -07:00
Jeremy Soller 5ae7b7efe7 Use new semaphore to prevent spinning 2020-12-23 12:20:19 -07:00
Mateusz Tabaka 79643c293b Fix formatiing issues 2020-09-30 11:40:38 +02:00
Jeremy Soller 36bb60cacc Do not unmap stack while it is being used, add a comment to fix it later 2020-09-09 18:49:44 -06:00
Jeremy Soller 5af8e3ca35 Merge branch 'bump-fmap' into 'master'
Use renamed fmap call

See merge request redox-os/relibc!305
2020-08-17 12:36:11 +00:00
jD91mZM2 e33aea434f Use renamed fmap call 2020-08-17 13:57:39 +02:00
jD91mZM2 eaee4e6329 Emulate brk 2020-08-15 18:44:22 +02:00
jD91mZM2 6952a079ae Fix CI 2020-08-07 14:16:45 +00:00
Jeremy Soller 5d45042d5d Correct more asm! usages 2020-08-02 13:38:29 -06:00
Jeremy Soller f2c2d7c52e Fix compilation on newer nightly, update nightly to 2020-08-01 2020-08-02 12:24:49 -06:00
jD91mZM2 4c148c1860 Make munmap use funmap2 2020-07-30 13:39:20 +02:00
4lDO2 a5e02650d7 Remove ptrace write call. 2020-07-25 22:30:38 +02:00
4lDO2 e38d185870 Use fmap2 to support passing an address. 2020-07-25 22:30:38 +02:00
Jeremy Soller d6b03de7a4 Align stack to 128 bytes 2020-07-19 21:04:16 -06:00
oddcoder 37a462de5d Apply cargo fmt to the whole repo 2020-07-19 21:27:38 +02:00
oddcoder f4f68a3441 Make use of mspaces 2020-07-18 21:03:46 +02:00
oddcoder 3a8817072c Initialize the mspaces of allocator and keep track of it 2020-07-18 21:03:20 +02:00
oddcoder 9a1efda121 Initial allocator structure 2020-07-18 20:54:30 +02:00
Wren Turkal 865b7962a1 Add implmentation for fwide posix function.
This function is used to set the orientation of a stream to either
byte-oriented or wchar-oriented.

More info on this function is here:
https://man7.org/linux/man-pages/man3/fwide.3p.html

This implementation only impmlemnts the manual switching and does
not yet guard against using a byte-oriented stream with wchar
functions and vice versa. Those step will come in additional
commits.

Signed-off-by: Wren Turkal <wt@penguintechs.org>
2020-07-08 14:33:06 -07:00
jD91mZM2 56e1eceb28 Replace AllocStringWriter with CVec 2020-06-29 17:44:57 +02:00
jD91mZM2 39ce623d2d Fix bind/connect's AF_UNIX socket path... again
I don't really know for sure what all these silly rules are, but I think
I got it now...
2020-06-29 11:36:07 +02:00
jD91mZM2 f8b49936bc Various unix socket fixes (+socketpair!) 2020-06-27 16:39:50 +02:00
jD91mZM2 cdc9aa06e3 Fix getpeername
Rust's TcpListener fails because of the address format being wrong. The format
comes from `accept`, but there we internally use this function.
2020-06-19 13:56:06 +02:00
oddcoder 92d6735e3f Add more scanf tests 2020-06-03 23:20:53 +02:00
Jeremy Soller a6fffd3fb5 Add getrandom and sys/random.h 2020-05-22 11:50:54 -06:00
Jeremy Soller 2cf3ccae72 Fix import of user_regs_struct 2020-05-21 20:01:47 -06:00
Jeremy Soller 06429ccc4c Fix redox socket inner_get_name 2020-05-21 14:59:22 -06:00
oddcoder de03566158 Enable RTLD debugging protocol system-wide
This patch makes use of the data structures and functions impelemented
in the last patch to enable RTLD debugging protocol as per SVR4
2020-04-13 12:39:51 +02:00