Exploit database

GH-fa5c871fea38479ff88e7c6b646acfd5

fracturelabs/spring4shell_victim

GitHubNot listedPoC
Download repository ZIP

Sources for CVE-2022-22965

88 sources

Preferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source

Repository files3

Files from this repository share one source choice. Supporting files may cover other vulnerabilities.

src/main/java/io/fracturelabs/SpringBootController.java

Java · 768 bytes
package io.fracturelabs;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class SpringBootController {
	@GetMapping("/")
	public String safeGetHandler() {
		return "GET / is not vulnerable";
	}

	@PostMapping("/")
	public String safePostHandler() {
		return "POST / is not vulnerable";
	}

	@GetMapping("/vulnerable")
	public String vulnGetHandler(ExampleBean bean) {
		return "GET /vulnerable is vulnerable - check for a shell";
	}

	@PostMapping("/vulnerable")
	public String vulnPostHandler(ExampleBean bean) {
		return "POST /vulnerable is vulnerable - check for a shell";
	}
}