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 base64 | |
import hashlib | |
from Cryptodome.Cipher import AES # from pycryptodomex v-3.10.4 | |
from Cryptodome.Random import get_random_bytes | |
HASH_NAME = "SHA256" | |
IV_LENGTH = 12 | |
ITERATION_COUNT = 65536 | |
KEY_LENGTH = 32 |
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.NoSuchPaddingException; | |
import javax.crypto.SecretKey; | |
import javax.crypto.SecretKeyFactory; | |
import javax.crypto.spec.GCMParameterSpec; | |
import javax.crypto.spec.PBEKeySpec; | |
import javax.crypto.spec.SecretKeySpec; | |
import java.nio.ByteBuffer; | |
import java.nio.charset.Charset; | |
import java.nio.charset.StandardCharsets; |
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 base64 | |
import hashlib | |
from Cryptodome.Cipher import AES # from pycryptodomex v-3.10.4 | |
from Cryptodome.Random import get_random_bytes | |
HASH_NAME = "SHA256" | |
IV_LENGTH = 16 | |
ITERATION_COUNT = 65536 | |
KEY_LENGTH = 32 |
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.SecretKey; | |
import javax.crypto.SecretKeyFactory; | |
import javax.crypto.spec.IvParameterSpec; | |
import javax.crypto.spec.PBEKeySpec; | |
import javax.crypto.spec.SecretKeySpec; | |
import java.nio.ByteBuffer; | |
import java.security.SecureRandom; | |
import java.security.spec.KeySpec; | |
import java.util.Arrays; |
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
<html> | |
<head> | |
<title> Thai Text only </title> | |
</head> | |
<link href="style.css" rel="stylesheet" type="text/css" /> | |
<script src="http://code.jquery.com/jquery-1.7.1.min.js"></script> | |
<script> | |
$(document).ready(function(){ | |
$('.thai').on('input', function (event) { | |
this.value = this.value.replace(/[^\u0E00-\u0E7F0-9]/g, ''); |
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.test.basic.dao; | |
import com.test.model.BaseDO; | |
import com.test.model.GridRequest; | |
import com.test.model.GridResponse; | |
public interface BasicDAO { | |
public BaseDO get(Class klass, Number id); | |