File Transfer

binsec academy GmbH Pentest Training Hacking

After we have “built“ an exploit locally on our attacking machine, we still have to transfer it to the target system. Here, we will discover that in fact many roads lead to Rome, and we are going to show three example procedures:

1. The Swiss Army Knife netcat is once again the forerunner for file transfers. Here, we only have to read the input from our desired file on the client side and divert the output into a file on the server side. Using our attacker scenario, this would work as follows:

Attacker

nc -q0 ${target server} ${target port} < ${file}

Target system

nc -l -p ${local port} > ${file}

2. Aside from netcat, we could also use the secure shell protocol SSH, which requires us to have a user with ssh access for our target system. Indeed, we rarely run into this situation in practice, but we have nevertheless learned about the password usage of users. If the above condition applies, we can transfer a file to the target system via the secure copy protocol (scp):

 scp ${file} ${user}@${target system}:${filing location}

3. A more creative solution would be to launch a web server on our attacker machine, place the file in its DocumentRoot and access it from the target system, using wget or curl, for example.

binsec academy GmbH - Online IT Security Training with Practical Focus

binsec academy GmbH is provider of online IT security training, offering practical, lab-based courses for professionals. The academy provides hands-on training in areas such as penetration testing and secure software development. Participants gain practical experience through realistic lab environments, including simulations of company networks and applications. Courses are available in multiple programming languages and align with standards like OWASP Top 10 and PCI DSS. Upon successful completion, participants receive certifications such as the Binsec Academy Certified Pentest Professional (BACPP) and Binsec Academy Certified Secure Coding Professional (BACSCP), demonstrating their ability to identify and remediate security vulnerabilities.

Goto binsec acadmy GmbH

binsec GmbH – Experts in Penetration Testing

binsec GmbH is a German IT security company focused on professional penetration testing. With over 10 years of experience, the team conducts in-depth penetration tests on networks, web applications, APIs, and mobile apps. Certified experts systematically identify and document security vulnerabilities to support organizations in improving their security and meeting compliance requirements.

Goto binsec GmbH

Contact

binsec GmbH
Solmsstraße 41
60486 Frankfurt am Main
Germany

Legal notice

Director: Patrick Sauer
Authorized Officer: Dominik Sauer, Florian Zavatzki
Registration: Frankfurt am Main, HRB97277
Turnover Tax Identification No.: DE290966808