NCNU-OpenSource
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Owners
        • Signed-in users
        • Everyone
        Owners Signed-in users Everyone
      • Write
        • Owners
        • Signed-in users
        • Everyone
        Owners Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights
    • Engagement control
    • Transfer ownership
    • Delete this note
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Versions and GitHub Sync Note Insights Sharing URL Help
Menu
Options
Engagement control Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Owners
  • Owners
  • Signed-in users
  • Everyone
Owners Signed-in users Everyone
Write
Owners
  • Owners
  • Signed-in users
  • Everyone
Owners Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       owned this note    owned this note      
    Published Linked with GitHub
    Subscribed
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    Subscribe
    ###### tags: `lsa` # 111 LSA 期中考題 - 筆試 ## 規則 ![](https://i.imgur.com/hJueRO7.png) - 如有問題請舉手發問。 - 請勿編輯本頁面。 - 請勿以私訊或聊天室等任何方式彼此溝通。 - 當然也請不要直接實體溝通啦... 那算作弊哦 - **通訊軟體請關閉** - 可以上網自由地找資料、補充這學期相對應的共筆頁面。 - 上機需要 DEMO,DEMO 時若助教發現答案錯誤,學生可以有一次修正機會。 - 筆試部分,Google 表單繳交前,請舉手找助教,在助教面前繳交。 - 請用**學校信箱**回答問卷 :::danger **沒在助教面前繳交者,視同沒交** ::: :::warning 本次考試作答環境以 Ubuntu 20.04 為主 ::: **We Are Watching You.** ## 筆試 62% + 25% ### 綜合 1. Ubuntu 在台灣推廣的負責人是誰? **(2%)** 2. 如果 ssh 到一台經常連線的 server 中間發生 MITM (Man-in-the-middle attack) 會出現什麼狀況?**(3%)** 請問 ssh 是利用什麼機制去偵測 MITM?**(3%)** 3. 系統中哪個檔案存放真正的使用者密碼(須回答完整路徑)? **(2%)** 4. 系統中哪一個特殊的使用者的家目錄預設不是在 `/home/` 底下?**(2%)** 5. 請解釋何為 swap 空間?**(2%)** 如果沒規劃 swap 空間會發生什麼事情? **(2%)** 6. 請說明 CSMA/CD (Carrier Sense Multiple Access / Collision Detection) 和 CSMA/CA (Carrier Sense Multiple Access / Collision Avoidance) 不同之處? **(3%)** 舉例分別運用於哪種網路環境 **(3%)** 7. 使用 `adduser` 指令新增兩個使用者 `使用者1` `使用者2`,不加任何額外的參數,且沒有更動過任何權限,請回答以下問題,並解釋 1. `使用者1` 可以跑去 `使用者2` 家目錄下新增檔案嗎?**(1%)** 為甚麼? **(2%)** 2. 接下來如果把 `使用者1` 的 uid 改成 `使用者2` 的 uid,這樣 `使用者1` 可以在 `使用者2` 的家目錄下新增檔案嗎? **(1%)** 為甚麼? **(2%)** 3. 再接下來 `使用者1` 可以回到自己的家目錄下新增檔案嗎?**(1%)** 為甚麼? **(2%)** 8. 請說明在本機上瀏覽器的網址列中輸入某個 FQDN (例如:`im.ncnu.edu.tw`) 後,系統的哪個檔案紀錄了 DNS 的解析順序 **(1%)** 請說明解析的順序 (查找 IP 的過程)。**(2%)** 9. 如果有某個 FQDN (例如:`im.ncnu.edu.tw`),要下什麼命令才能看到 IPv6 的值? **(3%)** 10. 請列出連線到 `ftp.ubuntu-tw.org` 會經過哪些 hop (提示:應用 ICMP ) **(4%)** 11. 在 nginx/1.18.0 (Ubuntu 預設版本) 的環境下,要新增一個虛擬主機的設定檔,但是先不啟用的話,要放在哪個目錄?**(1%)**呈上題,若要啟用該設定檔的話,該如何操作?**(2%)** 12. 假設當前目錄下含有多個檔案,檔案內容如下,請問要下什麼命令才能達到以下需求? > ![](https://i.imgur.com/c0cTNa1.png) 1. 請列出含有 LSA 的檔案(要都大寫),並顯示詳細資訊 **(1%)** 2. 承上題,只印出 `權限 擁有者 檔案大小 檔名` **(1%)** 3. 承上題,並將這些檔案大小要由小到大輸出於螢幕上 **(1%)** ### IPtables ![](https://i.imgur.com/l4cropw.png) 1. 請寫出符合以下要求的 iptables 命令 - LAN 裡的機器可以連出去外網 **(2%)** - DMZ 裡的 s3 可以 ssh 到 Firewall **(2%)** - 其餘 DMZ 裡的主機不能連到 Firewall **(2%)** ### IP 1. 請算出 172.22.187.14/20 - 網段的 IP 範圍 **(1%)** - network ID 為多少 **(1%)** - broadcast 的 IP 為多少 **(1%)** ### ssh ![](https://i.imgur.com/0s8y2Cw.png) + ServerA public IP 163.22.17.70 + ServerB 只有內網 IP 192.168.0.10 1. 請問利用 SSH forward agent 的技術進到 internal zone ,需要下什麼指令設定 forward agent **(1%)**?接著連線至internal zone **(1%)** 2. 請問將 ServerB 8787 port 上的服務導到自己機器上的 7777 port 上需要下什麼命令 (提示: tunnel 經過 MID ) **(4%)** ### [加分題] 1. 請說明貼圖中命令的意思 (5%) 1. ![](https://i.imgur.com/sQpw3Cb.png =40%x) (1%) 2. ![](https://i.imgur.com/IiohuIa.png =40%x) (1%) 3. ![](https://i.imgur.com/Zm2RbBs.png =40%x) (1%) 4. ![](https://i.imgur.com/BP8bVfz.png =40%x) (1%) 5. ![](https://i.imgur.com/RIejVbs.png =40%x) (1%) > [貼圖來自 - 工程師的浪漫](https://store.line.me/stickershop/product/1439141/zh-Hant?from=sticker) 2. 以下是助教的常用 ID,請寫出他的全名並舉出一個他在本學期分享的主題。 **( 一個助教全名 2 分,主題 2 分)** 1. Huei_Lin_Lin 2. chofinn 3. Alanjy Huang 4. PengLaiRenOu 5. squid_xoxo

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully