主頁 >  其他 > 執行緒通信, 網路編程 , IP , 埠 ,URL, 網路爬蟲 ,UDP, TCP

執行緒通信, 網路編程 , IP , 埠 ,URL, 網路爬蟲 ,UDP, TCP

2021-07-26 07:02:32 其他

執行緒通信
多執行緒之間打成通信溝通的效果,協作完成業務需求

Object:
wait() 執行緒等待 當呼叫某一個物件 的wait方法,當前執行緒就會進入到與這個物件相關的等待池中進行等待--->等待阻塞,等待被喚醒
會讓出cpu的資源,并且會釋放物件的鎖
notify() 喚醒執行緒 當呼叫一個物件的notify方法,會喚醒當前物件等待池中正在等待的執行緒,喚醒某一個
這個執行緒會進入到就緒狀態,要想要運行: 1)cpu的調度 2)獲取物件鎖

wait(ms) 阻塞等待指定時間
notifyAll() 喚醒全部

wait與notify必須使用在一個同步環境下,用于控制多執行緒之間協調作業問題,保證資料安全

sleep與wait之間區別
sleep : 執行緒休眠 抱著資源睡覺: 讓出cpu資源,抱著物件的鎖

人車共用街道:
街道 : 紅綠燈 boolean flag 綠燈-->人走 true 紅燈-->車走 false ns南北走向 we東西走向
人 : ns南北
車 : we東西

生產者消費者模式:
通過信號燈法
*/
public class Class001_Wait {
public static void main(String[] args) {
Street street = new Street(); //共享街道
new Thread(new Person(street)).start();
new Thread(new Car(street)).start();
}
}

//街道
class Street{
//紅綠燈
private boolean flag = false;

//ns
public synchronized void ns(){
//判斷是否為綠燈
if(flag){
/* try {
Thread.sleep(1000);
} catch (InterruptedException e) {
e.printStackTrace();
}*/
System.out.println("人走......");
//紅綠燈變為紅燈
flag=false;
//喚醒對方執行緒
this.notify();
//自己等待
try {
this.wait();
} catch (InterruptedException e) {
e.printStackTrace();
}

}
}

//we
public synchronized void we(){
if(!flag){
/*try {
Thread.sleep(1000);
} catch (InterruptedException e) {
e.printStackTrace();
}*/
System.out.println("車走......");
//紅綠燈變為紅燈
flag=true;
//喚醒對方執行緒
this.notify();
//自己等待
try {
this.wait();
} catch (InterruptedException e) {
e.printStackTrace();
}
}
}
}
//人
class Person implements Runnable{
//街道
private Street street = null;

public Person(Street street) {
this.street = street;
}

@Override
public void run() {
while(true){
street.ns();
}
}
}

//車
class Car implements Runnable{
//街道
private Street street = null;

public Car(Street street) {
this.street = street;
}

@Override
public void run() {
while(true){
street.we();
}
}
}


網頁編程 : 上層的應用
網路編程 : 底層,關注資料如何傳輸,如何存盤
節點 : 網路電子設備
節點與節點之間組成網路
IP : 表示節點
埠 : 區分不同的軟體
URL : 互聯網中資源的指標,統一資源定位符
協議 : 合同,標準,規范
傳輸層協議 :
UDP : 相當于寫信 只管寫只管發 效率高 不安全 大小存在限制
TCP : 相當于打電話 面向連接 安全性高 效率低 大小沒有限制 ****

IP :
定義網路中的節點 (網路電子設備,手機,電腦,路由器...)
分為 : IPV4(4個位元組,32位) IPV6 (128位)
特殊IP:
192.168.0.0~192.168.255.255 非注冊IP,供組織內部使用
127.0.0.1 本地IP
localhost : 本地域名
域名與IP之間的關系: DNS決議器

java.net包
InetAddress 類表示Internet協議(IP)地址


*/
public class Class001_IP {
public static void main(String[] args) throws UnknownHostException {
//static InetAddress getByName(String host) 根據主機名稱確定主機的IP地址,
//static InetAddress getLocalHost() 回傳本地主機的地址,
InetAddress address1 = InetAddress.getLocalHost();
System.out.println(address1); //DESKTOP-KHNV6UD/192.168.16.236
System.out.println(address1.getHostName());
System.out.println(address1.getHostAddress());

InetAddress address2 = InetAddress.getByName("www.baidu.com");
System.out.println(address2);
System.out.println(address2.getHostName());
System.out.println(address2.getHostAddress());
}
}

IP : 定位節點
埠 : 區分軟體
埠號 2個位元組 0~65535
同一協議下埠號不能沖突
建議使用8000以上的,8000以下稱為預留埠

常見的埠:
80 : http
8080 : tomcat
1521 : Oracle
3306 : Mysql

InetSocketAddress 此類實作IP套接字地址(IP地址+埠號)它也可以是一對(主機名+埠


public class Class002_Port {
public static void main(String[] args) {
//InetSocketAddress(String hostname, int port) 根據主機名和埠號創建套接字地址,
//InetSocketAddress(InetAddress addr, int port) 根據IP地址和埠號創建套接字地址,
InetSocketAddress in = new InetSocketAddress("localhost",8989);
System.out.println(in);
System.out.println(in.getHostName());
System.out.println(in.getPort());
}
}

URL
同一資源定位符,指向萬維網上的“資源”的指標,

組成:
協議: http
域名: www.baidu.com
埠號: 80
資源: index.html
提交資料: name=zhangsan&pwd=123
錨點: #a

互聯網 的三大基石:
html
http
url

URL 類


public class Class003_URL {
public static void main(String[] args) throws MalformedURLException {
//URL(String spec) 從 String表示創建 URL物件,
//URL(String protocol, String host, int port, String file)
URL url = new URL("https://www.baidu.com:80/index.html?name=zhangsan&pwd=123#a");

System.out.println(url);
System.out.println("協議:"+url.getProtocol());
System.out.println("域名:"+url.getHost());
System.out.println("埠:"+url.getPort());
System.out.println("資源:"+url.getFile());
System.out.println("資源:"+url.getPath());
System.out.println("資源:"+url.getQuery());
System.out.println("資源:"+url.getRef());
}
}

網路爬蟲


public class Class004_Spider {
public static void main(String[] args) throws IOException {
//1.定義URL
URL url = new URL("https://www.baidu.com/index.html");
//2.獲取流 : InputStream openStream() 打開與此 URL的連接并回傳 InputStream以從該連接讀取,
InputStream is = url.openStream();
//InputStreamReader 位元組輸入流轉位字符輸入流的節點流-->功能流
BufferedReader rd = new BufferedReader(new InputStreamReader(is));
String msg = null;
//3.讀入操作
while((msg = rd.readLine())!=null){
System.out.println(msg);
}
//4.關閉
rd.close();
is.close();
}
}

套接字:
傳輸層為應用層開辟的小口子
不同協議下Socket實作不同
UDP與TCP協議對Socket實作

UDP : 相當于寫信|有包裹|發短信 非面向連接 協議簡單,開銷小,效率高 不安全 大小由限制(一般不超過60k)
TCP : 相當于打電話 面向連接 效率低 安全 大小沒有限制
基于三次握手

UDP協議下發送端與接收端兩端平等
DatagramSocket 此類表示用于發送和接收資料報包的套接字,
DatagramSocket(int port) 構造一個資料報套接字并將其系結到本地主機上的指定埠,
void receive(DatagramPacket p) 從此套接字接收資料報包,
void send(DatagramPacket p) 從此套接字發送資料報包,

DatagramPacket 該類表示資料報包,
byte[] getData() 回傳資料緩沖區,
int getLength() 回傳要發送的資料的長度或接收的資料的長度,

資料的傳輸基于位元組陣列

UDP實作發送端: 基本流程
1.定義我是發送端
2.準備資料
3.打包
4.發送
5.關閉

*/
public class Class001_Send {
public static void main(String[] args) throws IOException {
// 1.定義我是發送端
DatagramSocket s = new DatagramSocket(9090);

System.out.println("-------------我是發送端-------------");

// 2.準備資料
byte[] arr = "你好".getBytes();
// 3.打包
DatagramPacket packet = new DatagramPacket(arr,0,arr.length,new InetSocketAddress("127.0.0.1",8989));
// 4.發送
s.send(packet);
// 5.關閉
s.close();
}
}

public class Class002_Receive {
public static void main(String[] args) throws IOException {
//1.定義我是接收端
DatagramSocket r = new DatagramSocket(8989);

System.out.println("-----------我是接收端------------");

//2.準備位元組陣列,打包
byte[] arr = new byte[1024];
DatagramPacket packet = new DatagramPacket(arr,arr.length);
//3.接收資料
r.receive(packet);
//4.處理資料
//byte[] getData() 回傳資料緩沖區,
//int getLength() 回傳要發送的資料的長度或接收的資料的長度,
byte[] newArr = packet.getData();
int len = packet.getLength();

System.out.println(new String(newArr,0,len));

//5.關閉
r.close();
}
}

客戶端 Socket
Socket(String host, int port) 創建流套接字并將其連接到指定主機上的指定埠號,
InputStream getInputStream()
OutputStream getOutputStream()
服務器 ServerSocket 該類實作服務器套接字,
ServerSocket(int port) 創建系結到指定埠的服務器套接字,
Socket accept() 偵聽對此套接字的連接并接受它,

tcp協議下傳輸資料基于IO流

tcp協議實作基本流程 : 客戶端
1.定義我是客戶端-->指定要請求的服務器的IP+埠
2.準備資料
3.獲取輸出流
4.輸出-->IO操作
5.刷出
6.關閉
*/
public class Class001_Client {
public static void main(String[] args) throws IOException {
System.out.println("-----------我是客戶端--------------");
// 1.定義我是客戶端-->指定要請求的服務器的IP+埠
Socket client = new Socket("localhost",9999);
System.out.println("-----------與服務器端建立連接--------------");
// 2.準備資料
String str = "你好";
// 3.獲取輸出流
DataOutputStream os = new DataOutputStream(new BufferedOutputStream(client.getOutputStream()));
// 4.輸出-->IO操作
os.writeUTF(str);
// 5.刷出
os.flush();
// 6.關閉
os.close();
client.close();
}
}

tcp協議實作基本流程 : 服務端
1.定義我是服務端
2.阻塞式監聽
3.獲取輸入流-->接收客戶端的請求資料
4.處理資料
5.關閉
*/
public class Class002_Server {
public static void main(String[] args) throws IOException {
System.out.println("-----------我是服務器端-----------");
// 1.定義我是服務端
ServerSocket server = new ServerSocket(9999);
// 2.阻塞式監聽
Socket client = server.accept();

System.out.println("-----------一個客戶端連接成功----------");

// 3.獲取輸入流-->接收客戶端的請求資料
DataInputStream is = new DataInputStream(new BufferedInputStream(client.getInputStream()));
String msg = is.readUTF();
// 4.處理資料
System.out.println(msg);
// 5.關閉
is.close();
client.close();
server.close();
}
}

 tcp 單向登錄: 客戶端
        1.定義客戶端
        2.準備資料(用戶輸入)
            1)輸入流
            2)用戶名與密碼
        3.獲取輸出流向服務器端發送資料(用戶名與密碼)
        4.刷出
        5.關閉
 */
public class Class003_LoginClient {
    public static void main(String[] args) throws IOException {
        System.out.println("-------我是客戶端---------");
        //1.定義客戶端
        Socket client = new Socket("localhost",9898);
        //2.準備資料(用戶輸入)
        //    1)輸入流
        BufferedReader rd = new BufferedReader(new InputStreamReader(System.in));
        //    2)用戶名與密碼
        System.out.println("請輸入用戶名");
        String username = rd.readLine();
        System.out.println("請輸入密碼");
        String password = rd.readLine();
        System.out.println(username+"-->"+password);
        //3.獲取輸出流向服務器端發送資料(用戶名與密碼)
        DataOutputStream os = new DataOutputStream(client.getOutputStream());
        //username=laopei&password=1234
        os.writeUTF("username="+username+"&password="+password);
        //4.刷出
        os.flush();
        //5.關閉
        os.close();
        rd.close();
        client.close();
    }
}

 tcp 單向登錄: 服務端
        1.定義我是服務器
        2.阻塞式監聽
        3.獲取輸入流接收客戶端發動的資料
        4.處理資料
        5.關閉

       要求: 服務器端接收到用戶輸入的用戶名與密碼,與指定的laopei,1234比較是否相等,相等本地輸出登錄成功,不相等輸出用戶名或密碼錯誤!!!
 */
public class Class003_LoginServer {
    public static void main(String[] args) throws IOException {
        System.out.println("--------我是服務器-------");
        //1.定義我是服務器
        ServerSocket server = new ServerSocket(9898);
        //2.阻塞式監聽
        Socket client = server.accept();
        System.out.println("一個客戶端連接成功........");
        //3.獲取輸入流接收客戶端發動的資料
        DataInputStream is = new DataInputStream(client.getInputStream());

        String msg = is.readUTF();  //username=laopei&password=1234
        //4.處理資料
        System.out.println(msg);
        //5.關閉
        is.close();
        client.close();
        server.close();
    }
}

 tcp 雙向登錄: 客戶端
        1.定義客戶端
        2.準備資料(用戶輸入)
            1)輸入流
            2)用戶名與密碼
        3.獲取輸出流向服務器端發送資料(用戶名與密碼)
        4.刷出
        5.獲取輸入流 從服務器端讀取回應
        6.關閉
 */
public class Class005_LoginTwoWayClient {
    public static void main(String[] args) throws IOException {
        System.out.println("-------我是客戶端---------");
        //1.定義客戶端
        Socket client = new Socket("localhost",9898);
        //2.準備資料(用戶輸入)
        //    1)輸入流
        BufferedReader rd = new BufferedReader(new InputStreamReader(System.in));
        //    2)用戶名與密碼
        System.out.println("請輸入用戶名");
        String username = rd.readLine();
        System.out.println("請輸入密碼");
        String password = rd.readLine();
        System.out.println(username+"-->"+password);
        //3.獲取輸出流向服務器端發送資料(用戶名與密碼)
        DataOutputStream os = new DataOutputStream(client.getOutputStream());
        //username=laopei&password=1234
        os.writeUTF("username="+username+"&password="+password);
        //4.刷出
        os.flush();

        //5.獲取輸入流 從服務器端讀取回應
        DataInputStream is = new DataInputStream(client.getInputStream());
        System.out.println(is.readUTF());

        //6.關閉
        is.close();
        os.close();
        rd.close();
        client.close();
    }
}

tcp 雙向登錄: 服務端
        1.定義我是服務器
        2.阻塞式監聽
        3.獲取輸入流接收客戶端發動的資料
        4.處理資料
        5.獲取輸出流 把結果回應 給客戶端
        6.刷出
        7.關閉

       要求: 服務器端接收到用戶輸入的用戶名與密碼,與指定的laopei,1234比較是否相等,相等本地輸出登錄成功,不相等輸出用戶名或密碼錯誤!!!
 */
public class Class006_LoginTwoWayServer {
    public static void main(String[] args) throws IOException {
        System.out.println("--------我是服務器-------");
        //1.定義我是服務器
        ServerSocket server = new ServerSocket(9898);
        //2.阻塞式監聽
        Socket client = server.accept();
        System.out.println("一個客戶端連接成功........");
        //3.獲取輸入流接收客戶端發動的資料
        DataInputStream is = new DataInputStream(client.getInputStream());
        String msg = is.readUTF();  //username=laopei&password=1234
        //4.處理資料
        System.out.println(msg);
        //處理1)
        /*String str = "username=laopei&password=1234";
        if(str.equals(msg)){
            System.out.println("登錄成功");
        }else{
            System.out.println("登錄失敗");
        }*/

        //2)
        String username = null;
        String password = null;
        String[] strs = msg.split("&");
        for(String s:strs){
            String[] arr = s.split("=");
            if("username".equals(arr[0])){
                username = arr[1];
            }else if("password".equals(arr[0])){
                password = arr[1];
            }
        }

        //5.獲取輸出流 把結果回應 給客戶端
        DataOutputStream os = new DataOutputStream(client.getOutputStream());

        if("laopei".equals(username) && "1234".equals(password)){
            os.writeUTF("登錄成功");
        }else{
            os.writeUTF("登錄失敗");
        }

        //6.刷出
        os.flush();
        //7.關閉
        os.close();
        is.close();
        client.close();
        server.close();
    }
}
多用戶登錄服務器端
        通過回圈可以實作多用戶登錄
        但是服務器只能排隊對不同的客戶端做回應
 */
public class Class007_MulLoginTwoWayServer {
    public static void main(String[] args) throws IOException {
        System.out.println("--------我是服務器-------");
        //1.定義我是服務器
        ServerSocket server = new ServerSocket(9898);
        //2.阻塞式監聽
        boolean flag = true;
        while(flag){
           Socket client = server.accept();
           System.out.println("一個客戶端連接成功........");
           //3.獲取輸入流接收客戶端發動的資料
           DataInputStream is = new DataInputStream(client.getInputStream());
           String msg = is.readUTF();
           //4.處理資料
           String username = null;
           String password = null;
           String[] strs = msg.split("&");
           for(String s:strs){
               String[] arr = s.split("=");
               if("username".equals(arr[0])){
                   username = arr[1];
               }else if("password".equals(arr[0])){
                   password = arr[1];
               }
           }

           //5.獲取輸出流 把結果回應 給客戶端
           DataOutputStream os = new DataOutputStream(client.getOutputStream());

           if("laopei".equals(username) && "1234".equals(password)){
               os.writeUTF("登錄成功");
           }else{
               os.writeUTF("登錄失敗");
           }

           //6.刷出
           os.flush();
           //7.關閉
           os.close();
           is.close();
           client.close();
       }
        server.close();
    }
}

多用戶登錄服務器端
        通過多執行緒實作
 */
public class Class008_MulLoginTwoWayServer {
    public static void main(String[] args) throws IOException {
        System.out.println("--------我是服務器-------");
        //1.定義我是服務器
        ServerSocket server = new ServerSocket(9898);
        //2.阻塞式監聽
        boolean flag = true;
        while(flag){
           Socket client = server.accept();
           System.out.println("一個客戶端連接成功........");

           //開啟執行緒為上面監聽到客戶端回應
            new Thread(new Channel(client)).start();

       }
        server.close();
    }

    static class Channel implements Runnable{
        private Socket client = null;
        private DataInputStream is = null;
        private  DataOutputStream os = null;

        public Channel(Socket client) {
            this.client = client;
            try {
                is = new DataInputStream(client.getInputStream());
                os = new DataOutputStream(client.getOutputStream());
            } catch (IOException e) {
                e.printStackTrace();
            }
        }

        //讀入資料
        public String read(){
            String msg = null;
            try {
                msg = is.readUTF();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return msg;
        }

        //寫出
        public void write(String msg){
            try {
                os.writeUTF(msg);
                os.flush();
            } catch (IOException e) {
                e.printStackTrace();
            }
        }

        //關閉資源
        public void close(){
            if(os!=null){
                try {
                    os.close();
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            if(is!=null){
                try {
                    is.close();
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            if(client!=null){
                try {
                    client.close();
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
        }


        @Override
        public void run() {
            //獲取輸入流接收客戶端發動的資料
            String msg = read();

            //處理資料
            String username = null;
            String password = null;
            String[] strs = msg.split("&");
            for(String s:strs){
                String[] arr = s.split("=");
                if("username".equals(arr[0])){
                    username = arr[1];
                }else if("password".equals(arr[0])){
                    password = arr[1];
                }
            }

            //獲取輸出流 把結果回應 給客戶端
            if("laopei".equals(username) && "1234".equals(password)){
                write("登錄成功");
            }else{
                write("登錄失敗");
            }

            //關閉
            close();
        }
    }
}

轉載請註明出處,本文鏈接:https://www.uj5u.com/qita/290019.html

標籤:其他

上一篇:收藏!程式員必備的軟體開發工具大全!(附高速下載地址)

下一篇:華為21級技術高管整理「程式員優化手冊」究竟有多強

標籤雲
其他(157675) Python(38076) JavaScript(25376) Java(17977) C(15215) 區塊鏈(8255) C#(7972) AI(7469) 爪哇(7425) MySQL(7132) html(6777) 基礎類(6313) sql(6102) 熊猫(6058) PHP(5869) 数组(5741) R(5409) Linux(5327) 反应(5209) 腳本語言(PerlPython)(5129) 非技術區(4971) Android(4554) 数据框(4311) css(4259) 节点.js(4032) C語言(3288) json(3245) 列表(3129) 扑(3119) C++語言(3117) 安卓(2998) 打字稿(2995) VBA(2789) Java相關(2746) 疑難問題(2699) 细绳(2522) 單片機工控(2479) iOS(2429) ASP.NET(2402) MongoDB(2323) 麻木的(2285) 正则表达式(2254) 字典(2211) 循环(2198) 迅速(2185) 擅长(2169) 镖(2155) 功能(1967) .NET技术(1958) Web開發(1951) python-3.x(1918) HtmlCss(1915) 弹簧靴(1913) C++(1909) xml(1889) PostgreSQL(1872) .NETCore(1853) 谷歌表格(1846) Unity3D(1843) for循环(1842)

熱門瀏覽
  • 網閘典型架構簡述

    網閘架構一般分為兩種:三主機的三系統架構網閘和雙主機的2+1架構網閘。 三主機架構分別為內端機、外端機和仲裁機。三機無論從軟體和硬體上均各自獨立。首先從硬體上來看,三機都用各自獨立的主板、記憶體及存盤設備。從軟體上來看,三機有各自獨立的作業系統。這樣能達到完全的三機獨立。對于“2+1”系統,“2”分為 ......

    uj5u.com 2020-09-10 02:00:44 more
  • 如何從xshell上傳檔案到centos linux虛擬機里

    如何從xshell上傳檔案到centos linux虛擬機里及:虛擬機CentOs下執行 yum -y install lrzsz命令,出現錯誤:鏡像無法找到軟體包 前言 一、安裝lrzsz步驟 二、上傳檔案 三、遇到的問題及解決方案 總結 前言 提示:其實很簡單,往虛擬機上安裝一個上傳檔案的工具 ......

    uj5u.com 2020-09-10 02:00:47 more
  • 一、SQLMAP入門

    一、SQLMAP入門 1、判斷是否存在注入 sqlmap.py -u 網址/id=1 id=1不可缺少。當注入點后面的引數大于兩個時。需要加雙引號, sqlmap.py -u "網址/id=1&uid=1" 2、判斷文本中的請求是否存在注入 從文本中加載http請求,SQLMAP可以從一個文本檔案中 ......

    uj5u.com 2020-09-10 02:00:50 more
  • Metasploit 簡單使用教程

    metasploit 簡單使用教程 浩先生, 2020-08-28 16:18:25 分類專欄: kail 網路安全 linux 文章標簽: linux資訊安全 編輯 著作權 metasploit 使用教程 前言 一、Metasploit是什么? 二、準備作業 三、具體步驟 前言 Msfconsole ......

    uj5u.com 2020-09-10 02:00:53 more
  • 游戲逆向之驅動層與用戶層通訊

    驅動層代碼: #pragma once #include <ntifs.h> #define add_code CTL_CODE(FILE_DEVICE_UNKNOWN,0x800,METHOD_BUFFERED,FILE_ANY_ACCESS) /* 更多游戲逆向視頻www.yxfzedu.com ......

    uj5u.com 2020-09-10 02:00:56 more
  • 北斗電力時鐘(北斗授時服務器)讓網路資料更精準

    北斗電力時鐘(北斗授時服務器)讓網路資料更精準 北斗電力時鐘(北斗授時服務器)讓網路資料更精準 京準電子科技官微——ahjzsz 近幾年,資訊技術的得了快速發展,互聯網在逐漸普及,其在人們生活和生產中都得到了廣泛應用,并且取得了不錯的應用效果。計算機網路資訊在電力系統中的應用,一方面使電力系統的運行 ......

    uj5u.com 2020-09-10 02:01:03 more
  • 【CTF】CTFHub 技能樹 彩蛋 writeup

    ?碎碎念 CTFHub:https://www.ctfhub.com/ 筆者入門CTF時時剛開始刷的是bugku的舊平臺,后來才有了CTFHub。 感覺不論是網頁UI設計,還是題目質量,賽事跟蹤,工具軟體都做得很不錯。 而且因為獨到的金幣制度的確讓人有一種想去刷題賺金幣的感覺。 個人還是非常喜歡這個 ......

    uj5u.com 2020-09-10 02:04:05 more
  • 02windows基礎操作

    我學到了一下幾點 Windows系統目錄結構與滲透的作用 常見Windows的服務詳解 Windows埠詳解 常用的Windows注冊表詳解 hacker DOS命令詳解(net user / type /md /rd/ dir /cd /net use copy、批處理 等) 利用dos命令制作 ......

    uj5u.com 2020-09-10 02:04:18 more
  • 03.Linux基礎操作

    我學到了以下幾點 01Linux系統介紹02系統安裝,密碼啊破解03Linux常用命令04LAMP 01LINUX windows: win03 8 12 16 19 配置不繁瑣 Linux:redhat,centos(紅帽社區版),Ubuntu server,suse unix:金融機構,證券,銀 ......

    uj5u.com 2020-09-10 02:04:30 more
  • 05HTML

    01HTML介紹 02頭部標簽講解03基礎標簽講解04表單標簽講解 HTML前段語言 js1.了解代碼2.根據代碼 懂得挖掘漏洞 (POST注入/XSS漏洞上傳)3.黑帽seo 白帽seo 客戶網站被黑帽植入劫持代碼如何處理4.熟悉html表單 <html><head><title>TDK標題,描述 ......

    uj5u.com 2020-09-10 02:04:36 more
最新发布
  • 2023年最新微信小程式抓包教程

    01 開門見山 隔一個月發一篇文章,不過分。 首先回顧一下《微信系結手機號資料庫被脫庫事件》,我也是第一時間得知了這個訊息,然后跟蹤了整件事情的經過。下面是這起事件的相關截圖以及近日流出的一萬條資料樣本: 個人認為這件事也沒什么,還不如關注一下之前45億快遞資料查詢渠道疑似在近日復活的訊息。 訊息是 ......

    uj5u.com 2023-04-20 08:48:24 more
  • web3 產品介紹:metamask 錢包 使用最多的瀏覽器插件錢包

    Metamask錢包是一種基于區塊鏈技術的數字貨幣錢包,它允許用戶在安全、便捷的環境下管理自己的加密資產。Metamask錢包是以太坊生態系統中最流行的錢包之一,它具有易于使用、安全性高和功能強大等優點。 本文將詳細介紹Metamask錢包的功能和使用方法。 一、 Metamask錢包的功能 數字資 ......

    uj5u.com 2023-04-20 08:47:46 more
  • vulnhub_Earth

    前言 靶機地址->>>vulnhub_Earth 攻擊機ip:192.168.20.121 靶機ip:192.168.20.122 參考文章 https://www.cnblogs.com/Jing-X/archive/2022/04/03/16097695.html https://www.cnb ......

    uj5u.com 2023-04-20 07:46:20 more
  • 從4k到42k,軟體測驗工程師的漲薪史,給我看哭了

    清明節一過,盲猜大家已經無心上班,在數著日子準備過五一,但一想到銀行卡里的余額……瞬間心情就不美麗了。最近,2023年高校畢業生就業調查顯示,本科畢業月平均起薪為5825元。調查一出,便有很多同學表示自己又被平均了。看著這一資料,不免讓人想到前不久中國青年報的一項調查:近六成大學生認為畢業10年內會 ......

    uj5u.com 2023-04-20 07:44:00 more
  • 最新版本 Stable Diffusion 開源 AI 繪畫工具之中文自動提詞篇

    🎈 標簽生成器 由于輸入正向提示詞 prompt 和反向提示詞 negative prompt 都是使用英文,所以對學習母語的我們非常不友好 使用網址:https://tinygeeker.github.io/p/ai-prompt-generator 這個網址是為了讓大家在使用 AI 繪畫的時候 ......

    uj5u.com 2023-04-20 07:43:36 more
  • 漫談前端自動化測驗演進之路及測驗工具分析

    隨著前端技術的不斷發展和應用程式的日益復雜,前端自動化測驗也在不斷演進。隨著 Web 應用程式變得越來越復雜,自動化測驗的需求也越來越高。如今,自動化測驗已經成為 Web 應用程式開發程序中不可或缺的一部分,它們可以幫助開發人員更快地發現和修復錯誤,提高應用程式的性能和可靠性。 ......

    uj5u.com 2023-04-20 07:43:16 more
  • CANN開發實踐:4個DVPP記憶體問題的典型案例解讀

    摘要:由于DVPP媒體資料處理功能對存放輸入、輸出資料的記憶體有更高的要求(例如,記憶體首地址128位元組對齊),因此需呼叫專用的記憶體申請介面,那么本期就分享幾個關于DVPP記憶體問題的典型案例,并給出原因分析及解決方法。 本文分享自華為云社區《FAQ_DVPP記憶體問題案例》,作者:昇騰CANN。 DVPP ......

    uj5u.com 2023-04-20 07:43:03 more
  • msf學習

    msf學習 以kali自帶的msf為例 一、msf核心模塊與功能 msf模塊都放在/usr/share/metasploit-framework/modules目錄下 1、auxiliary 輔助模塊,輔助滲透(埠掃描、登錄密碼爆破、漏洞驗證等) 2、encoders 編碼器模塊,主要包含各種編碼 ......

    uj5u.com 2023-04-20 07:42:59 more
  • Halcon軟體安裝與界面簡介

    1. 下載Halcon17版本到到本地 2. 雙擊安裝包后 3. 步驟如下 1.2 Halcon軟體安裝 界面分為四大塊 1. Halcon的五個助手 1) 影像采集助手:與相機連接,設定相機引數,采集影像 2) 標定助手:九點標定或是其它的標定,生成標定檔案及內參外參,可以將像素單位轉換為長度單位 ......

    uj5u.com 2023-04-20 07:42:17 more
  • 在MacOS下使用Unity3D開發游戲

    第一次發博客,先發一下我的游戲開發環境吧。 去年2月份買了一臺MacBookPro2021 M1pro(以下簡稱mbp),這一年來一直在用mbp開發游戲。我大致分享一下我的開發工具以及使用體驗。 1、Unity 官網鏈接: https://unity.cn/releases 我一般使用的Apple ......

    uj5u.com 2023-04-20 07:40:19 more