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 com.squareup.okhttp.OkHttpClient; | |
import com.squareup.okhttp.Request; | |
import com.squareup.okhttp.Response; | |
import javax.crypto.Cipher; | |
import java.security.*; | |
import java.security.spec.PKCS8EncodedKeySpec; | |
import java.security.spec.X509EncodedKeySpec; | |
import java.util.Base64; |
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
package com.thexcoders.RSA_server.controllers; | |
import com.thexcoders.RSA_server.EncryptionManager; | |
import org.springframework.web.bind.annotation.GetMapping; | |
import org.springframework.web.bind.annotation.RestController; | |
@RestController | |
public class ApplicationController { | |
@GetMapping("getSecretMessage") |
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
package com.thexcoders.RSA_server; | |
import javax.crypto.Cipher; | |
import java.security.KeyFactory; | |
import java.security.PublicKey; | |
import java.security.spec.X509EncodedKeySpec; | |
import java.util.Base64; | |
public class EncryptionManager { | |
private PublicKey publicKey; |
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 React, {useEffect} from 'react'; | |
import {useState} from "react"; | |
import SideBar from "../../components/sideBar/SideBar"; | |
import FactureBody from "./FactureBody"; | |
import './facture.css' | |
import axios from "axios"; | |
import {JwtHelper} from "../../helperClasses/jwtHelper"; | |
import {loadFacturesService} from "../../services/FactureServices"; |
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 javax.crypto.Cipher; | |
import javax.crypto.KeyGenerator; | |
import javax.crypto.SecretKey; | |
import javax.crypto.spec.GCMParameterSpec; | |
import javax.crypto.spec.SecretKeySpec; | |
import java.util.Base64; | |
/** | |
* Possible KEY_SIZE values are 128, 192 and 256 | |
* Possible T_LEN values are 128, 120, 112, 104 and 96 |
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 javax.crypto.Cipher; | |
import javax.crypto.KeyGenerator; | |
import javax.crypto.SecretKey; | |
import javax.crypto.spec.GCMParameterSpec; | |
import javax.crypto.spec.SecretKeySpec; | |
import java.util.Base64; | |
/** | |
* Possible KEY_SIZE values are 128, 192 and 256 | |
* Possible T_LEN values are 128, 120, 112, 104 and 96 |
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 javax.crypto.Cipher; | |
import javax.crypto.KeyGenerator; | |
import javax.crypto.SecretKey; | |
import javax.crypto.spec.GCMParameterSpec; | |
import javax.crypto.spec.SecretKeySpec; | |
import java.util.Base64; | |
/** | |
* Possible KEY_SIZE values are 128, 192 and 256 | |
* Possible T_LEN values are 128, 120, 112, 104 and 96 |
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 javax.crypto.Cipher; | |
import javax.crypto.KeyGenerator; | |
import javax.crypto.SecretKey; | |
import javax.crypto.spec.GCMParameterSpec; | |
import javax.crypto.spec.SecretKeySpec; | |
import java.util.Base64; | |
/** | |
* Possible KEY_SIZE values are 128, 192 and 256 | |
* Possible T_LEN values are 128, 120, 112, 104 and 96 |
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 sqlite3 | |
conn = sqlite3.connect("database.db") | |
curs = conn.cursor() | |
curs.execute("CREATE TABLE users(id INTEGER PRIMARY KEY, login TEXT, password TEXT, nom TEXT,prenom TEXT, type INTEGER, spes INTEGER, prix INTEGER, max Integer)") | |
curs.execute("CREATE TABLE appoitnments(id INTEGER PRIMARY KEY, id_med INTEGER, id_pat INTEGER, date_app DATE, state INTEGER, motif TEXT)") | |
res = curs.execute("INSERT INTO users values (1,'m','password', 'Amine', 'Alami',0,0,300, 10)") | |
res = curs.execute("INSERT INTO users values (2,'m1','password', 'Yousef', 'Alami',0,1,310, 10)") | |
res = curs.execute("INSERT INTO users values (3,'m2','password', 'Ibrahim', 'Alami',0,2,330, 10)") |
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
<?xml version="1.0" encoding="utf-8"?> | |
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | |
package="com.example.mytodo"> | |
<application | |
android:allowBackup="true" | |
android:icon="@mipmap/ic_launcher" | |
android:label="@string/app_name" | |
android:roundIcon="@mipmap/ic_launcher_round" | |
android:supportsRtl="true" |
OlderNewer