Skip to content

Instantly share code, notes, and snippets.

Go up and never stop....

Johnny Lê lechidung

Go up and never stop....
View GitHub Profile
View gist:a1129056556d3d5290297bb782a50034
sudo certbot certonly --server --manual --preferred-challenges dns -d ''
View Teecom

Describe the network protection controls used by your organization to restrict public access to databases, file servers, and desktop/developer endpoints.

  • Access to the Amazon Aurora database through the network is disabled and standard ports are closed. The database is only accessible through a socket on the server itself.
  • The reverse proxy only serves whitelisted directories that are only from sources controlled by Teecom used (AWS Amplify).
  • API endpoints are password protected (PBKDF2 & SHA512 encryption, salted, and stretched for thousands of rounds).
  • Login credentials are always transmitted securely over SSL.

Describe how your organization individually identifies employees who have access to Amazon Information, and restricts employee access to Amazon information on a need- to-know basis.

  • If all your employees are properly assigned separate users and given only relevant access rights: Access rights are provided to employees based on their role within the company and are progressive, base
View gist:87e3e27853d39b0806c41539add5c4e7
1. Vào Setting > Plugins
2. Vào Manage plugin repo....
3. Thêm
4. Qua tab market tìm Eval Reset để install
View sample-suggest
{"lineList":[{"name":"\u6771\u4eac\u99c5 (\u6771\u4eac)","code":"2001","param":"st","pf":"13","ln":"2161","st_name":"\u6771\u4eac","valcode":"22828"},{"name":"\u6771\u6210\u7530\u99c5 (\u5343\u8449)","code":"2418","param":"st","pf":"12","ln":"2260","st_name":"\u6771\u6210\u7530","valcode":"22413"},{"name":"\u6771\u798f\u5bfa\u99c5 (\u4eac\u90fd)","code":"6132","param":"st","pf":"26","ln":"6643","st_name":"\u6771\u798f\u5bfa","valcode":"25720"},{"name":"\u6771\u3042\u305a\u307e\u99c5(\u4e80\u6238\u7dda) (\u6771\u4eac)","code":"2262030","param":"st","pf":"13","ln":"2262","st_name":"\u6771\u3042\u305a\u307e","valcode":"22923"},{"name":"\u6771\u4e09\u56fd\u99c5(\u5fa1\u5802\u7b4b\u7dda) (\u5927\u962a)","code":"6701020","param":"st","pf":"27","ln":"6701","st_name":"\u6771\u4e09\u56fd","valcode":"26147"}],"geoList":[{"name":"\u798f\u5ca1\u770c\u798f\u5ca1\u5e02\u6771\u533a","oaza":"","code":"40131","pfName":"\u798f\u5ca1\u770c","pfCode":"40","geoName":"\u798f\u5ca1\u5e02\u6771\u533a","geoCode":"40131","breadcrumbs"
View Consistent type errors for internal functions
/*** PHP 7 ***/
strlen([]); // Warning: strlen() expects parameter 1 to be string, array given
array_chunk([], -1); // Warning: array_chunk(): Size parameter expected to be greater than 0
/*** PHP 8 ***/
strlen([]); // TypeError: strlen(): Argument #1 ($str) must be of type string, array given
array_chunk([], -1); // ValueError: array_chunk(): Argument #2 ($length) must be greater than 0
View Nullsafe operator
/*** PHP 7 ***/
$country = null;
if ($session !== null) {
$user = $session->user;
if ($user !== null) {
$address = $user->getAddress();
if ($address !== null) {
View Match
/*** PHP 7 ***/
switch (8.0) {
case '8.0':
$result = "Oh no!";
case 8.0:
$result = "This is what I expected";
echo $result;
View Union types
/*** PHP 7 ***/
class Number {
/** @var int|float */
private $number;
* @param float|int $number
public function __construct($number) {
$this->number = $number;
View Constructor property promotion
/*** PHP 7 ***/
class Point {
public float $x;
public float $y;
public float $z;
public function __construct(
float $x = 0.0,
float $y = 0.0,
float $z = 0.0,