panel icon indicating copy to clipboard operation
panel copied to clipboard

Cannot decompress file that is not an archive

Open EpicPlayerA10 opened this issue 1 year ago • 2 comments

Current Behavior

When I try to unarchive minecraft log file (example: /logs/2024-03-15-2.log.gz) then it wouldn't work and on the planel it would show this error: image

On wings it will throw this error:

wings[1917041]: 2024/03/15 22:32:22 [Recovery] 2024/03/15 - 22:32:22 panic recovered:
wings[1917041]: runtime error: invalid memory address or nil pointer dereference
wings[1917041]: runtime/panic.go:261 (0x451e97)
wings[1917041]: runtime/signal_unix.go:861 (0x451e65)
wings[1917041]: io/fs/stat.go:25 (0x504716)
wings[1917041]: io/fs/walk.go:118 (0x504c95)
wings[1917041]: github.com/pterodactyl/wings/server/filesystem/compress.go:113 (0xe532a4)
wings[1917041]: github.com/pterodactyl/wings/router/router_server_files.go:450 (0xfde38f)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xf9db8a)
wings[1917041]: github.com/pterodactyl/wings/router/middleware/middleware.go:158 (0xfe51c8)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xf9db8a)
wings[1917041]: github.com/pterodactyl/wings/router/middleware/middleware.go:186 (0xfe503c)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xf9db8a)
wings[1917041]: github.com/pterodactyl/wings/router/middleware/middleware.go:186 (0xfe4dfc)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xfa99dd)
wings[1917041]: github.com/gin-gonic/[email protected]/logger.go:240 (0xfa99a0)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xf9db8a)
wings[1917041]: github.com/pterodactyl/wings/router/middleware/middleware.go:51 (0xfd75e4)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xf9db8a)
wings[1917041]: github.com/pterodactyl/wings/router/middleware/middleware.go:42 (0xfd7638)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xfb405c)
wings[1917041]: github.com/pterodactyl/wings/router/middleware/middleware.go:135 (0xfb404a)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xf9db8a)
wings[1917041]: github.com/pterodactyl/wings/router/middleware/middleware.go:68 (0xfe4686)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xf9db8a)
wings[1917041]: github.com/pterodactyl/wings/router/middleware/middleware.go:33 (0xfe4638)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xfaa839)
wings[1917041]: github.com/gin-gonic/[email protected]/recovery.go:102 (0xfaa827)
wings[1917041]: github.com/gin-gonic/[email protected]/context.go:174 (0xfa8a9a)
wings[1917041]: github.com/gin-gonic/[email protected]/gin.go:620 (0xfa872d)
wings[1917041]: github.com/gin-gonic/[email protected]/gin.go:576 (0xfa825c)
wings[1917041]: net/http/server.go:2938 (0x6ea24d)
wings[1917041]: net/http/server.go:2009 (0x6e6133)
wings[1917041]: runtime/asm_amd64.s:1650 (0x470dc0)

Expected Behavior

Minecraft log file should be unarchived.

Steps to Reproduce

  1. Setup minecraft server and start it
  2. Try to unarchive one of the log files
  3. See the error

Panel Version

1.11.5

Wings Version

1.11.11

Games and/or Eggs Affected

Minecraft (Paper)

Docker Image

ghcr.io/pterodactyl/yolks:java_17

Error Logs

No response

Is there an existing issue for this?

  • [X] I have searched the existing issues before opening this issue.
  • [X] I have provided all relevant details, including the specific game and Docker images I am using if this issue is related to running a server.
  • [X] I have checked in the Discord server and believe this is a bug with the software, and not a configuration issue with my specific system.

EpicPlayerA10 avatar Mar 15 '24 22:03 EpicPlayerA10

I know this hasn't been released yet, but as far as I can tell, the patch introduced in https://github.com/pterodactyl/wings/commit/f1c5bbd42d423986e7017b4f3c43057a1b7d1717 does not work yet

It no longer panics, but it can't cast here: https://github.com/pterodactyl/wings/blob/f1c5bbd42d423986e7017b4f3c43057a1b7d1717/server/filesystem/compress.go#L194-L197

I may be misunderstanding but the Gz doesn't seem to implement Extractor, just Compressor

I will see if I can find out more in the meantime

NotGeri avatar Mar 26 '24 18:03 NotGeri

Confirmed this is still not working on the latest release and latest develop branch - Reopening.

danny6167 avatar May 05 '24 12:05 danny6167