1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 11:18:11 +00:00
Commit graph

1159 commits

Author SHA1 Message Date
Ali Mohammad Pur
b16918ccb9 pro: Only attempt to parse a proxy url if it is provided
Otherwise we'd end up trying to parse an empty string as a proxy url
which is certainly not one.
2022-04-09 14:36:28 +02:00
Ali Mohammad Pur
f9fc28931f pro: Accept an optional proxy to tunnel the download through
For now, this only accepts the format `socks5://ip:port` (i.e. the
hostname has to be an ipv4, and the port must be present).
2022-04-09 12:21:43 +02:00
Hendiadyoin1
f602bbf135 LibX86+disasm: Use an output format closer to objdump
This mainly does two things,
1. Removes spaces after commas
2. Elides "0x" and leading zeros in most contexts

Remaining differences are:
1. objdump always has memory size annotations
   We lack these and probably have some annotations wrong
2. Boolean check names
   We use jump-zero, while objdump uses jump-equal for example
3. We sometimes add "00 00" symbols, which objdump elides
4. We always demangle (This is a good thing)
5. We always resolve relocations (This is a good thing)
6. We seem to detect some symbols differently/incorrectly
2022-04-07 16:50:34 +02:00
Hendiadyoin1
5ee85aaa5d disasm: Print instruction bytes
This prints 7 instruction bytes per line, which is enough for most
x86-64 instructions (rex+opcode+mod/rm+imm32) and is also what
objdump uses.

Co-authored-by: Simon Wanner <skyrising@pvpctutorials.de>
2022-04-07 16:50:34 +02:00
brapru
3dbb4bc3a6 Utilities: Update arp to use newer APIs
Updates the arp command to use Core::System for the socket and
ioctl calls.

Updates command line arguments to StringView.
2022-04-05 12:43:18 +02:00
brapru
26b8155530 Utilities: Pledge inet in arp command
Previously the arp command would crash when trying to set/delete from
the table.
2022-04-05 12:43:18 +02:00
Ali Mohammad Pur
431776ebb7 js: Print the accumulator instead of the returned value in BC mode
The REPL is supposed to show the last value (and not the _returned_
value), so use the accumulator register as the 'value'.
2022-04-05 11:46:48 +02:00
Timothy Flynn
b36c3a68d8 js: Convert non-UTF-8 encoded files to UTF-8 before parsing 2022-04-05 00:14:29 +01:00
Brian Gianforcaro
7eaf1cfdc2 ls: Use Core::System::pledge(..) instead of LibC API 2022-04-03 17:13:51 -07:00
Brian Gianforcaro
af3751e4dd Utilities: Use default execpromises parameter to pledge(..) 2022-04-03 17:13:51 -07:00
Linus Groh
4f35c206e4 lscpu: Show hypervisor_vendor_id if present 2022-04-03 23:20:33 +02:00
Linus Groh
0f27432ec6 Kernel+SystemMonitor+lscpu: Rename 'CPUID' -> 'Vendor ID'
This is what the Intel manual, as well as Linux's cpuinfo calls it.
2022-04-03 23:20:33 +02:00
Brendan Coles
fd6d87df82 netstat: Resolve ports to service names 2022-04-03 12:08:41 +02:00
James Mintram
cd2f67c4ea top: Add support for quitting top by pressing q 2022-04-02 23:48:17 +01:00
Thomas Symalla
77add584fa Userland: Fix crash when inputting non-tty device into ps
This PR aims to fix #13299 by avoiding assertion failure
while trying to determine the pseudo tty when inputting
any non-tty device device into ps.
2022-04-02 21:49:16 +02:00
Idan Horowitz
086969277e Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
Kenneth Myhra
6581cf47ab test: Port to LibMain 2022-03-30 09:53:11 +01:00
safarp
704e1d13f4 AK: Allow printing wide characters using %ls modifier 2022-03-30 11:30:43 +04:30
Kenneth Myhra
c843f2e3a5 seq: Port to LibMain 2022-03-29 21:28:29 -07:00
Kenneth Myhra
1ee93e0fe7 tty: Port to LibMain 2022-03-29 21:28:29 -07:00
Kenneth Myhra
cf154ec0d9 tt: Port to LibMain 2022-03-29 21:28:29 -07:00
Kenneth Myhra
ab9a78a305 tr: Utilize TRY more
This converts the local functions to return ErrorOr<T> and utilizes TRY
more.
2022-03-29 21:28:29 -07:00
Kenneth Myhra
e548b2cff2 tr: Port to LibMain 2022-03-29 21:28:29 -07:00
Kenneth Myhra
8bd7c5b3d5 test_env: Port to LibMain 2022-03-29 21:28:29 -07:00
Kenneth Myhra
3df8c9e9de test-unveil: Port to LibMain 2022-03-29 21:28:29 -07:00
Kenneth Myhra
f4aef35e6e test-pthread: Port to LibMain and let local functions return ErrorOr<T>
This ports 'test-pthread' to LibMain and converts the local functions of
the program to return ErrorOr<T>.
2022-03-29 21:28:29 -07:00
Kenneth Myhra
d69f3aa958 test-fuzz: Allow listing fuzzing targets without specifying input file 2022-03-29 21:28:29 -07:00
Kenneth Myhra
4994718d8d test-fuzz: Port to LibMain
Also use StringView in place of raw C strings and String.
2022-03-29 21:28:29 -07:00
Kenneth Myhra
b47a9ab4dc test-bindtodevice: Port to LibMain
This ports 'test-bindtodevice' to LibMain and convert the local 'test'
function to return ErrorOr<T>.
2022-03-29 21:28:29 -07:00
Kenneth Myhra
e302fac34b kcov-example: Port to LibMain 2022-03-29 21:28:29 -07:00
Kenneth Myhra
234025ee53 telws: Port to LibMain 2022-03-29 21:28:29 -07:00
Kenneth Myhra
bb4994d67b run-tests: Port to LibMain 2022-03-29 21:28:29 -07:00
Kenneth Myhra
7d87f0d56d markdown-check: Use Core::ArgsParser 2022-03-29 21:28:29 -07:00
Kenneth Myhra
de7d333d43 markdown-check: Port to LibMain 2022-03-29 21:28:29 -07:00
Ali Mohammad Pur
67357fe984 LibXML: Add a fairly basic XML parser
Currently this can parse XML and resolve external resources/references,
and read a DTD (but not apply or verify its rules).
That's good enough for _most_ XHTML documents as the HTML 5 spec
enforces its own rules about document well-formedness, and does not make
use of XML DTDs (aside from a list of predefined entities).

An accompanying `xml` utility is provided that can read and dump XML
documents, and can also run the XML conformance test suite.
2022-03-28 23:11:48 +02:00
Kenneth Myhra
f38076e596 disk_benchmark: TRY more stuff :^) 2022-03-27 08:33:24 -04:00
Kenneth Myhra
c0f15ebcbb disk_benchmark: Core::ArgsParser to parse arguments 2022-03-27 08:33:24 -04:00
Kenneth Myhra
122778b9ac tee: Port to LibMain and move to SerenityOS code patterns
This patch ports the utility 'tee' to LibMain and converts a larger part
of its code to our SerenityOS patterns.
2022-03-26 18:39:58 +00:00
Ali Mohammad Pur
4a331c73f8 ls: Remove leading dashes from ArgsParser argument name
Otherwise the full argument would be "----ignore-backups", which is most
certainly not correct :^)
2022-03-26 21:34:56 +04:30
Liav A
d7c7e6e496 Utilities/ps: Don't assume the kernel can provide real TTY paths 2022-03-26 11:01:49 +01:00
Lenny Maiorani
f268a91227 Utilities: Use default constructors/destructors
https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#cother-other-default-operation-rules

"The compiler is more likely to get the default semantics right and
you cannot implement these functions better than the compiler."
2022-03-24 20:09:26 -07:00
Nicholas Cellino
626ea5007a sql: Re-prompt user for input after unrecognized command
This fixes a bug in the SQL REPL where after a user enters an
unrecognized command, the REPL would not print another "> " prompt and
would not accept any more input.
2022-03-24 07:25:04 -04:00
Kenneth Myhra
546a6a80a7 readlink: Use StringView instead of const char* 2022-03-24 11:57:51 +01:00
Kenneth Myhra
45ac5e90b7 readlink: Port to LibMain 2022-03-24 11:57:51 +01:00
Kenneth Myhra
4a57be824c Userland+Tests: Convert File::read_link() from String to ErrorOr<String>
This converts the return value of File::read_link() from String to
ErrorOr<String>.

The rest of the change is to support the potential of an Error being
returned and subsequent release of the value when no Error is returned.
Unfortunately at this stage none of the places affected can utililize
our TRY() macro.
2022-03-24 11:57:51 +01:00
Nicholas Cellino
0e51d99322 sql: Do not indent next line when current one is blank
Previously, if a user pressed Enter without typing a command at
the SQL REPL, the next line would be automatically indented. This
change makes it so we check if there were any tokens in the command
before applying the indentation logic.
2022-03-23 15:27:09 -04:00
int16
a4d96c159c Mount: Implement wxallowed mount option 2022-03-22 12:20:19 +01:00
Nicholas Cellino
1db7c423db disk_benchmark: Port to LibMain 2022-03-22 11:51:32 +01:00
Brian Gianforcaro
0a9e84aff0 readelf: Port to LibMain 2022-03-22 11:39:20 +01:00
Brian Gianforcaro
575fcc42c3 purge: Port to LibMain 2022-03-22 11:39:20 +01:00