欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

使用curl命令查看服務器端口開放情況的方法

 更新時間:2024年05月08日 11:33:12   作者:sun0322  
這篇文章主要介紹了如何使用curl命令查看服務器端口開放情況的方法,文中通過代碼示例和圖文講解的非常詳細,具有一定的參考價值,需要的朋友可以參考下

1.ssh端口 22

curl -v 10.10.10.205:22

curl -v 10.10.10.205:22
*   Trying 10.10.10.205:22...
* Connected to 10.10.10.205 (10.10.10.205) port 22
> GET / HTTP/1.1
> Host: 10.10.10.205:22
> User-Agent: curl/8.4.0
> Accept: */*
>
* Received HTTP/0.9 when not allowed
* Closing connection
curl: (1) Received HTTP/0.9 when not allowed

2.mysql數(shù)據(jù)庫端口 3306

curl -v 10.10.10.205:3306

curl -v 10.10.10.205:3306
*   Trying 10.10.10.205:3306...
* Connected to 10.10.10.205 (10.10.10.205) port 3306
> GET / HTTP/1.1
> Host: 10.10.10.205:3306
> User-Agent: curl/8.4.0
> Accept: */*
>
* Received HTTP/0.9 when not allowed
* Closing connection
curl: (1) Received HTTP/0.9 when not allowed

3.web應用端口 (Jellyfin 8082)

curl -v 10.10.10.205:8082

curl -v 10.10.10.205:8082
*   Trying 10.10.10.205:8082...
* Connected to 10.10.10.205 (10.10.10.205) port 8082
> GET / HTTP/1.1
> Host: 10.10.10.205:8082
> User-Agent: curl/8.4.0
> Accept: */*
>
< HTTP/1.1 302 Found
< Content-Length: 0
< Date: Tue, 07 May 2024 13:22:55 GMT
< Server: Kestrel
< Location: /web/index.html
<
* Connection #0 to host 10.10.10.205 left intact

(wordpress 8088)

curl -v 10.10.10.205:8088

curl -v 10.10.10.205:8088
*   Trying 10.10.10.205:8088...
* Connected to 10.10.10.205 (10.10.10.205) port 8088
> GET / HTTP/1.1
> Host: 10.10.10.205:8088
> User-Agent: curl/8.4.0
> Accept: */*
>
< HTTP/1.1 200 OK
< Date: Tue, 07 May 2024 13:20:40 GMT
< Server: Apache/2.4.57 (Debian)
< X-Powered-By: PHP/8.2.18
< Link: <http://10.10.10.205:8088/wp-json/>; rel="https://api.w.org/"
< Vary: Accept-Encoding
< Transfer-Encoding: chunked
< Content-Type: text/html; charset=UTF-8
<
<!DOCTYPE html>
。。。
。。。

(tomcat 8080)

curl -v 10.10.10.205:8080

curl -v 10.10.10.205:6666
*   Trying 10.10.10.205:6666...
* connect to 10.10.10.205 port 6666 failed: Connection refused
* Failed to connect to 10.10.10.205 port 6666 after 2051 ms: Couldn't connect to server
* Closing connection
curl: (7) Failed to connect to 10.10.10.205 port 6666 after 2051 ms: Couldn't connect to server
 
C:\Users>curl -v 10.10.10.205:8080
*   Trying 10.10.10.205:8080...
* Connected to 10.10.10.205 (10.10.10.205) port 8080
> GET / HTTP/1.1
> Host: 10.10.10.205:8080
> User-Agent: curl/8.4.0
> Accept: */*
>
< HTTP/1.1 200
< Content-Type: text/html;charset=UTF-8
< Transfer-Encoding: chunked
< Date: Tue, 07 May 2024 13:19:25 GMT
<
 
 
 
<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8" />
        <title>Apache Tomcat/9.0.30</title>
。。。
。。。

4.不存在的端口

curl -v 10.10.10.205:6666

curl -v 10.10.10.205:6666
*   Trying 10.10.10.205:6666...
* connect to 10.10.10.205 port 6666 failed: Connection refused
* Failed to connect to 10.10.10.205 port 6666 after 2051 ms: Couldn't connect to server
* Closing connection
curl: (7) Failed to connect to 10.10.10.205 port 6666 after 2051 ms: Couldn't connect to server

5.被防火墻阻擋的端口

連接一段時間后,提示timeout

以上就是使用curl命令查看服務器端口開放情況的方法的詳細內容,更多關于curl查看端口開放情況的資料請關注腳本之家其它相關文章!

相關文章

  • 通過shell腳本循環(huán)進入目錄執(zhí)行命令的方法

    通過shell腳本循環(huán)進入目錄執(zhí)行命令的方法

    今天小編就為大家分享一篇通過shell腳本循環(huán)進入目錄執(zhí)行命令的方法,具有很好的參考價值,希望對大家有所幫助。一起跟隨小編過來看看吧
    2018-06-06
  • python實現(xiàn)Linux異步epoll代碼

    python實現(xiàn)Linux異步epoll代碼

    本文提供了python實現(xiàn)Linux異步epoll的代碼,供大家參考使用,希望對你有幫助
    2013-11-11
  • Linux bash Shell中的變量類型詳解

    Linux bash Shell中的變量類型詳解

    這篇文章主要介紹了Linux bash Shell中的變量類型詳解,變量類型共分為本地變量、局部變量、環(huán)境變量、位置變量和特殊變量等,需要的朋友可以參考下
    2015-06-06
  • Linux使用文本編輯器vi常用命令

    Linux使用文本編輯器vi常用命令

    vi就是一種功能強大的文本編輯器,而vim則是高級版的vi,不但可以用不同顏色顯示文字內容,還能進行諸如shell腳本、C語言程序編輯等功能,可以作為程序編輯器。下面通過本文給大家介紹linux 文本編輯器vi常用命令,一起看看吧
    2017-09-09
  • Linux 下vim使用教程

    Linux 下vim使用教程

    Vim是從 vi 發(fā)展出來的一個文本編輯器。這篇文章給大家介紹Linux 下vim使用教程,感興趣的朋友跟隨腳本之家小編一起看看吧
    2018-07-07
  • Linux shell中如何獲取當前目錄

    Linux shell中如何獲取當前目錄

    這篇文章主要介紹了Linux shell中如何獲取當前目錄問題,具有很好的參考價值,希望對大家有所幫助。如有錯誤或未考慮完全的地方,望不吝賜教
    2023-07-07
  • 淺析Linux打包壓縮解壓縮命令大全(收藏)

    淺析Linux打包壓縮解壓縮命令大全(收藏)

    本文給大家分享Linux打包壓縮解壓縮命令大全,非常不錯,具有參考借鑒價值,需要的朋友參考下吧
    2017-09-09
  • Linux使用Split命令分割文件與合并的操作方法

    Linux使用Split命令分割文件與合并的操作方法

    Linux split是一個命令行工具,用于將文件分割成多個較小的文件,它可以按照文件大小、行數(shù)或者指定的分割符來進行分割,本文給大家介紹了Linux使用Split命令分割文件與合并的操作方法,需要的朋友可以參考下
    2024-03-03
  • linux下數(shù)據(jù)壓縮的幾種方法與查看方式(示例代碼)

    linux下數(shù)據(jù)壓縮的幾種方法與查看方式(示例代碼)

    這篇文章主要介紹了linux下數(shù)據(jù)壓縮的幾種方法與查看方式,本文給大家介紹的非常詳細,具有一定的參考借鑒價值,需要的朋友可以參考下
    2019-10-10
  • shell中set?-e的具體使用

    shell中set?-e的具體使用

    set?-e?是一個?Shell?命令,它用于在腳本運行時自動退出,本文主要介紹了shell中set?-e的具體使用,具有一定的參考價值,感興趣的可以了解一下
    2024-05-05

最新評論