Commit graph

208 commits

Author SHA1 Message Date
Haowei Wen 6d3e5856c2
Drop main arguments --proxyHost, --proxyPort, --proxyUser, --proxyPass 2020-09-11 20:55:16 +08:00
Haowei Wen c4a769271a
nanohttpd: refactor: rename myPort->port, myThread->listenerThread, myServerSocket->serverSocket 2020-08-26 20:44:18 +08:00
Haowei Wen cda96f96e1
nanohttpd: refactor: remove socket timeout parameter 2020-08-26 20:42:30 +08:00
Haowei Wen 85f38d47ac
nanohttpd: refactor: remove NanoHTTPD.LOG 2020-08-26 20:38:02 +08:00
Haowei Wen 728e5d0d61
nanohttpd: refactor: remove NanoHTTPD.closeAllConnections 2020-08-26 20:19:51 +08:00
Haowei Wen 848e6da6a9
nanohttpd: refactor: move NanoHTTPD.MIME_PLAINTEXT-> IOUtils.CONTENT_TYPE_TEXT 2020-08-26 20:15:28 +08:00
Haowei Wen 61b787aa4d
nanohttpd: refactor: remove Response.newFixedLength(String) 2020-08-26 20:15:27 +08:00
Haowei Wen 514f2829e2
nanohttpd: refactor: simplify keep-alive check 2020-08-26 20:15:27 +08:00
Haowei Wen f84afc976e
nanohttpd: refactor: add missing this. 2020-08-26 20:15:27 +08:00
Haowei Wen e56a68ecc3
nanohttpd: refactor: AsyncRunner: use concurrent data structures 2020-08-26 20:15:19 +08:00
Haowei Wen bac4022ada
nanohttpd: refactor: add ConnectionCloseException to signal connection closes normally 2020-08-26 20:04:34 +08:00
Haowei Wen e88f1eb009
nanohttpd: refactor: remove Response.lowerCaseHeader 2020-08-26 20:03:35 +08:00
Haowei Wen f0e635bff3
nanohttpd: refactor: move HTTPSession to a new file 2020-08-26 19:34:58 +08:00
Haowei Wen d2ee1cb282
nanohttpd: refactor: extract HTTPSession.readHeader() 2020-08-26 19:31:33 +08:00
Haowei Wen 854b0284bd
nanohttpd: refactor: remove IHTTPSession.execute() 2020-08-26 19:31:32 +08:00
Haowei Wen 5ca213f5cc
nanohttpd: refactor: replace remoteIpAddress & remoteHostName with remoteAddress 2020-08-26 19:31:11 +08:00
Haowei Wen 665a400f04
httpd: fix reverse proxy can't handle 204 properly 2020-08-26 18:23:07 +08:00
Haowei Wen 86feaa3273
nanohttpd: fix npe introduced in 2df9dde936 2020-08-26 15:23:03 +08:00
Haowei Wen 2df9dde936
nanohttpd: refactor x2 2020-08-26 00:35:22 +08:00
Haowei Wen 05f61d92c6
nanohttpd: refactor 2020-08-26 00:27:46 +08:00
Haowei Wen d72035a066
nanohttpd: reset parsedInputStream & continueSent between requests
fix #83

bug description:
if tcp keep-available is on, after processing a POST request,
parsedInputStream's value is retained. if the next request is a
GET request, HttpSession.getInputStream() will not return null
as expected.
2020-08-25 23:30:32 +08:00
yushijinhun 244fe2e969
logging: remove control characters to prevent messing up the console 2020-08-23 01:50:43 +08:00
yushijinhun e913d7d4d4
fix #81 2020-08-23 00:18:51 +08:00
yushijinhun 14741ad521
prevent logging output being redirected 2020-08-22 22:40:40 +08:00
yushijinhun 9b2075775e
add options for mojang namespace & legacy skin api polyfill
- add option: -Dauthlibinjector.mojangNamespace={default|enabled|disabled}
- add option: -Dauthlibinjector.legacySkinPolyfill={default|enabled|disabled}
- add metadata field: feature.no_mojang_namespace
- update options doc
2020-08-22 19:16:07 +08:00
yushijinhun 20224ede05
remove 'path' param from URLFilter.canHandle 2020-08-22 16:37:42 +08:00
yushijinhun 1ba5bbb678
refactor
YggdrasilConfiguration -> APIMetadata
InjectorInitializationException -> InitializationException
javaagent/AuthlibInjectorPremain -> Premain
2020-08-22 16:26:22 +08:00
yushijinhun 496baee488
refactor config & logging
replaced java.logging, fixed #80

deprecated options:
-Dauthlibinjector.debug=all => -Dauthlibinjector.debug
-Dauthlibinjector.mojang.proxy= => -Dauthlibinjector.mojangProxy=
2020-08-22 02:24:37 +08:00
yushijinhun 3ce68a3db2
update copyright year
forgotten in 0bd7134c81
2020-08-14 20:40:18 +08:00
yushijinhun d3da27444c
Use keep-available when processing ALI 2020-08-13 21:30:43 +08:00
yushijinhun 059dc2641d
Remove ExecutionEnvironment & authlibinjector.side
'authlibinjector.side' option becomes unnecessary now.
This commit discards 'authlibinjector.side' option defined in proposal #16.
2020-08-13 20:50:14 +08:00
yushijinhun b12dd75fa5
Forbid multiple ALI redirects (#78) 2020-08-13 20:49:47 +08:00
yushijinhun 0bd7134c81
Support HTTP redirects, fix #77 2020-08-12 19:33:06 +08:00
yushijinhun b4f571a88d
Update copyright years
I forgot to update this in e305dea256.

Commit message of e305dea256
shoud be `fix '@mojang' suffix broken since authlib 1.6.25`.
I can't amend this typo because force push is disabled.
2020-08-10 01:46:50 +08:00
yushijinhun e305dea256
fix '@mojang' suffix broken since authlib 1.5.23
fix #76
2020-08-07 16:43:29 +08:00
yushijinhun d05c005b39
Reimplement signing key injection 2020-05-01 00:47:52 +08:00
yushijinhun 71913d41ab
Put invokedynamic bootstrap method in target class 2020-04-30 00:19:18 +08:00
yushijinhun 106e13b17f
Revert "Add classloader exclusion to launchwrapper (#68)"
This reverts commit 2ac95074a6.
2020-04-29 23:34:12 +08:00
yushijinhun d3fa2a77eb
Refactor packages & classes structure 2020-04-29 23:30:23 +08:00
Haowei Wen 2ac95074a6
Add classloader exclusion to launchwrapper (#68) 2020-04-29 01:35:27 +08:00
Haowei Wen bc2a251dca
Update copyright year 2020-04-10 23:06:14 +08:00
Alexander Xia 59083e83ce
Fix compatibility with authlib 1.6.25 2020-04-10 19:40:02 +08:00
Hai-tun af9e793db3
Allow specifying packages to ignore (#63)
* Add parameter: authlibinjector.ignoredPackages

Co-authored-by: yushijinhun <yushijinhun@gmail.com>
2020-04-07 21:29:02 +08:00
yushijinhun e8a13e7ae2
Allow accessing Mojang with proxy
Implement #41
2019-02-05 16:31:49 +08:00
yushijinhun 90d37f9d0f
Allow whitelisted domains to be changed at runtime 2019-01-24 20:27:39 +08:00
yushijinhun 754e151b41
Refactor package structure 2019-01-24 19:40:50 +08:00
yushijinhun cb9ce1794b
[json-simple]crop 2019-01-24 19:40:50 +08:00
yushijinhun b4e97786b0
polish 2019-01-23 20:23:03 +08:00
yushijinhun 1003212d38
Use invokedynamic 2019-01-23 20:13:25 +08:00
yushijinhun a94528bb68
Implement class file version upgrading 2019-01-23 19:53:21 +08:00
yushijinhun 9eb3b0d738
Use Type.getMethodDescriptor 2019-01-23 18:47:29 +08:00
yushijinhun 244f7b1796
Use dynamic invocation to bypass launchwrapper/modlauncher 2019-01-22 20:57:31 +08:00
yushijinhun 925cc55266
Add missing license headers 2019-01-20 20:58:44 +08:00
yushijinhun 6252c0502d
Refactor agentmain 2019-01-20 18:35:38 +08:00
yushijinhun 8bd0f3b803
MC52974_1710Workaround supports forge 2019-01-20 17:33:34 +08:00
yushijinhun bee0998925
Support retransform 2019-01-20 16:17:43 +08:00
yushijinhun f2a447d58d
Workaround for MC-52974(1.7.10) (#35) 2019-01-20 13:35:50 +08:00
yushijinhun 090c7df79a
[nanohttpd]crop 2019-01-19 21:38:17 +08:00
yushijinhun 9dfd1bcacb
Use a new workaround for MC-52974
Instead of injecting signatures in the local http server, it modifies authlib
2019-01-19 20:58:11 +08:00
yushijinhun 6569238649
Only turn on MC-52974 workaround for affected versions 2019-01-19 20:53:58 +08:00
yushijinhun 980617e923
Add a simple workaround for MC-52974 2019-01-19 20:52:23 +08:00
yushijinhun 79873f126c
Add support for launchwrapper, fix #33
Thanks to @NekoCaffeine
2019-01-19 19:51:01 +08:00
yushijinhun 59d1197e06
Add license headers 2019-01-12 18:58:35 +08:00
yushijinhun 146c029779
Upgrade to asm 7.0 2018-12-31 14:43:20 +08:00
yushijinhun 27e775114c
Remove duplicate ldc transform log 2018-12-31 13:26:58 +08:00
yushijinhun 029782551d
Add prop: httpd.disable 2018-12-31 13:26:11 +08:00
yushijinhun c297c4debc
Remove unnecessary connection.connect()/disconnect() 2018-12-31 13:26:11 +08:00
yushijinhun 1148e0c6bc
polish 2018-12-31 13:26:11 +08:00
yushijinhun cbc1e8c664
Javadoc for URLFilter&URLProcessor&URLRedirector 2018-12-31 11:24:33 +08:00
yushijinhun eeda91c329
Support @mojang suffix 2018-12-31 11:24:33 +08:00
yushijinhun 9cfb6325a3
Support reverse proxy 2018-12-31 11:24:33 +08:00
yushijinhun bdd5f4bfcb
[nanohttpd]support chunked encoding&100-continue 2018-12-31 00:51:50 +08:00
yushijinhun f31e9f53dd
[nanohttpd]split into multi files 2018-12-30 21:16:27 +08:00
yushijinhun 352fb14667
[nanohttpd]crop 2018-12-30 21:14:17 +08:00
yushijinhun ffc96d0a05
[nanohttpd]code format 2018-12-30 17:02:17 +08:00
yushijinhun 6dccd97269
Import nanohttpd 2.3.1 source 2018-12-30 16:31:08 +08:00
yushijinhun 3572ff8eb5
Add YggdrasilClient 2018-12-30 15:04:28 +08:00
yushijinhun 5531c8a06e
Support Citizens2 2018-12-30 15:04:28 +08:00
yushijinhun 15f766ab29
Refactor URL replacing 2018-12-30 15:04:28 +08:00
yushijinhun ffd2a94b3d
Support multi signature keys 2018-12-30 15:04:27 +08:00
yushijinhun def9d9614e
[json-simple]Use LinkedHashMap in JSONObject 2018-12-30 15:04:13 +08:00
yushijinhun b59400f3dd
Shut up compile warnings 2018-12-30 14:38:27 +08:00
yushijinhun eb830c9c9f
Fix duplicate authlib log 2018-12-30 00:08:40 +08:00
yushijinhun 42ed5a9b1e
Apply AuthlibLogInterceptor only if necessary 2018-12-29 21:42:53 +08:00
yushijinhun 57e145d7da
Replace 'transform.skipped' logger with 'printUntransformed' property 2018-12-29 20:49:50 +08:00
yushijinhun d6cf905a38
Support intercepting logs from authlib 2018-11-25 00:05:47 +08:00
yushijinhun 1d73a05413
Move dump class feature into DumpClassListener 2018-11-24 14:39:27 +08:00
yushijinhun 1f5605c973
Add ClassLoadingListener interface 2018-11-24 14:32:22 +08:00
yushijinhun 36f3ef61eb
Support ALI(Api Location Indication) (#18) 2018-10-05 21:08:48 +08:00
yushijinhun 58d0b0e7a1
Merge branch 'protocol-omit' into ali 2018-10-05 19:29:11 +08:00
yushijinhun 390220b973
Detect client/server side (#16) 2018-10-05 19:14:08 +08:00
yushijinhun 1594f453f3
Prepend https:// when protocol is not specified (#17) 2018-10-05 18:44:57 +08:00
yushijinhun 0b81d69ff8
Move url slash appending out of YggdrasilConfiguration 2018-10-05 18:38:15 +08:00
yushijinhun 8dadd210fc
Warn if using HTTP 2018-10-05 18:36:16 +08:00
yushijinhun eebacfa567
Still print stacktrace when debug is on 2018-10-04 17:07:33 +08:00
yushijinhun e002f5f167
Do not print stacktrace on known exceptions 2018-10-04 16:27:44 +08:00
yushijinhun 84960bae35
Whitelist some packages 2018-09-30 20:50:22 +08:00
yushijinhun af35eb3ac4
Add feature.legacy_skin_api option 2018-09-23 23:13:40 +08:00
yushijinhun 29003c73cb
Add logging option transform.skipped 2018-09-23 22:59:48 +08:00
yushijinhun 8c615b618b
Refactor transform 2018-09-23 22:59:48 +08:00