Skip to content

Latest commit

 

History

History
420 lines (307 loc) · 7.65 KB

File metadata and controls

420 lines (307 loc) · 7.65 KB

Houdinis -

: MIT Python 3.8+ : 135/100 :

"Houdinis "

English | Português | Español | ****


Houdinis ·Harry Houdini""

  • ** 12 **: ShorGroverSimonHHLQAOAQPE
  • ** 31+ **: RSAECDSAAESTLSSSHPGP
  • ** **:
  • ** PQC **: KyberDilithiumFALCONSPHINCS+ (NIST)
  • ** **: IBM QuantumAWS BraketAzure QuantumGoogle Cirq
  • ** 85%+ **: 7,182+ CI/CD
  • ** **: 8,425+ Sphinx API 9 Jupyter

# 
git clone https://github.com/maurorisonho/Houdinis.git
cd Houdinis

# 
pip install -r requirements.txt

#  Docker 
docker build -t houdinis -f docker/Dockerfile .
docker run -it houdinis

from exploits.rsa_shor import RSAShorsAlgorithm

#  15  RSA 
rsa = RSAShorsAlgorithm(N=15)
factors = rsa.run()

print(f"15 : {factors['p']} × {factors['q']}")
# : 15 : 3 × 5

Grover

from exploits.grover_bruteforce import GroverAttack

#  16  AES 
grover = GroverAttack(key_size=16)
result = grover.quantum_key_search()

print(f": {result['speedup']}")
# : √(2^16) = 2^8 ( 256 )

10
IBMAWSAzureGoogle
31+
9

**9 Jupyter **:

  1. **Shor ** - RSA
  2. **Grover ** -
  3. **HNDL ** - ""
  4. **** - NIST PQC
  5. **** - QML
  6. **** -
  7. **IBM Quantum ** -
  8. **** -
  9. **** -

Houdinis/
  exploits/          # 31+ 
    rsa_shor.py       # RSA  Shor 
    grover_bruteforce.py  # Grover 
    simon_algorithm.py    # Simon 
    quantum_phase_estimation.py  # Shor  QPE
    amplitude_amplification.py   #  Grover
    side_channel_attacks.py      # 
    advanced_qml_attacks.py      # 
  scanners/          # 
    network_scanner.py         # 
    quantum_vuln_scanner.py    # 
    ssl_scanner.py             # TLS/SSL 
  quantum/           # 
    backend.py        #  (IBM, AWS, Azure, Google)
    simulator.py      # 
    __init__.py
  security/          # 
    owasp_auditor.py           # OWASP Top 10 
    automated_security_testing.py  # 
    secure_file_ops.py         # 
  utils/             # 
    disaster_recovery.py   # 
    monitoring.py          # Prometheus 
    auto_scaling.py        # 
    performance_benchmark.py  # 
  tests/             #  (85%+ )
    test_quantum_algorithms_advanced.py
    test_advanced_modules.py
    test_edge_cases.py
    test_integration_workflows.py
    test_security_validation.py
  notebooks/         # 9  Jupyter 
  docs/              # 32  (8,425+ )
  docker/            # Docker 

Shor RSA/ECC
Grover AES (√N)
Simon
HHL
QAOA
QPE
****
Deutsch-Jozsa /
Bernstein-Vazirani
**** QUBO

 :         RSA, ECDSA, DH, ECDH, ElGamal
 :         AES, 3DES, ChaCha20 ()
#⃣ :     MD5, SHA-1, SHA-256, SHA-3 ()
 :         TLS/SSL, SSH, IPsec, IKE, PGP
 :        (ECDSA), 
 :       NTRU, LWE, CVP, SVP
 PQC (NIST):  Kyber, Dilithium, FALCON, SPHINCS+

1. Shor RSA

from exploits.rsa_shor import RSAShorsAlgorithm

# 
shor = RSAShorsAlgorithm(
    N=15,  # 
    backend="qiskit_aer",  # 
    shots=1024
)

#  Shor 
result = shor.run()

if result['success']:
    print(f" !")
    print(f"   {result['N']} = {result['p']} × {result['q']}")
    print(f"   : {result['execution_time']:.2f}")

2. Grover AES

from exploits.grover_bruteforce import GroverAttack

#  32 
grover = GroverAttack(
    key_size=32,
    target_key="01010101010101010101010101010101"
)

result = grover.quantum_key_search()

print(f"  vs :")
print(f"   : 2^32 = {2**32:,} ")
print(f"   : √(2^32) = {2**16:,} ")
print(f"   : {result['speedup']}")

3.

from exploits.side_channel_attacks import SideChannelAnalyzer

analyzer = SideChannelAnalyzer()

# 
def vulnerable_compare(guess):
    secret = "123"
    if len(guess) != len(secret):
        return False
    for i in range(len(secret)):
        if guess[i] != secret[i]:
            return False
    return True

result = analyzer.timing_attack_string_comparison(
    comparison_func=vulnerable_compare,
    target_secret="123"
)

print(f" : {result.vulnerable}")
print(f"   : {result.confidence:.0%}")
print(f"   : {result.leaked_information}")

4. QML

from exploits.advanced_qml_attacks import QuantumModelStealingAttack

stealer = QuantumModelStealingAttack()

# 
result = stealer.extract_model_via_queries(
    num_queries=1000,
    input_dim=4
)

print(f" :")
print(f"   : {result.queries_made}")
print(f"   : {result.fidelity:.0%}")
print(f"   : {result.stolen_accuracy:.0%}")

(PQC)

Houdinis NIST PQC :

from exploits.kyber_attack import KyberAttack
from exploits.dilithium_attack import DilithiumAttack

#  CRYSTALS-Kyber (KEM)
kyber = KyberAttack(security_level=3)
result = kyber.timing_side_channel_attack()

#  CRYSTALS-Dilithium ()
dilithium = DilithiumAttack(security_level=3)
result = dilithium.nonce_reuse_attack()

PQC

from exploits.pqc_migration_analyzer import PQCMigrationAnalyzer

analyzer = PQCMigrationAnalyzer()

# 
report = analyzer.scan_codebase(
    path="./src",
    output_format="json"
)

print(f" :")
print(f"   : {report['vulnerable_count']}")
print(f"   PQC : {len(report['recommendations'])}")

Houdinis :

IBM Quantum Qiskit Aer
AWS Braket IonQ, Rigetti, OQC
Azure Quantum IonQ, Quantinuum Azure
Google Cirq Sycamore Cirq
NVIDIA cuQuantum GPU
PennyLane

: 85%+

# 
pytest tests/ -v --cov=. --cov-report=html

# 
pytest tests/test_quantum_algorithms_advanced.py -v
pytest tests/test_security_validation.py -v

# 
pytest -m "quantum" -v      # 
pytest -m "integration" -v  # 
pytest -m "security" -v     # 

  • : 85%+ (7,182+ )
  • : 92% ()
  • : 96.7% (), 97.2% ()
  • OWASP : 10/10
  • : 10/10
  • : 9.5/10

Docker & Kubernetes

Docker

# 
docker build -t houdinis -f docker/Dockerfile .

# 
docker run -it houdinis python exploits/rsa_shor.py

# Docker Compose
docker-compose -f docker/docker-compose.yml up

Kubernetes

#  Kubernetes
kubectl apply -f deploy/kubernetes/

#  pods
kubectl get pods -n houdinis

# 
kubectl logs -f deployment/houdinis -n houdinis

  1. Fork
  2. (git checkout -b feature/)
  3. (git commit -m '')
  4. (git push origin feature/)
  5. Pull Request

**MIT ** - LICENSE



Houdinis GitHub

GitHub stars


** ""**