
أداة بصمات محرك خادم GraphQL ترسل استعلامات حميدة ومشوهة لتحديد التقنية الخلفية وتقييم الدفاعات الأمنية عبر مصفوفة تهديدات GraphQL.
graphw00f (مستوحى من wafw00f) هي أداة التعرف على بصمة نقاط نهاية GraphQL (GQL)، حيث ترسل مزيجًا من الاستعلامات الآمنة والتالفة لتحديد محرك GraphQL الذي يعمل خلف الكواليس. يستخدم graphw00f مشروع مصفوفة تهديدات GraphQL لتوفير نظرة ثاقبة على الدفاعات الأمنية التي توفرها كل تقنية مباشرة، وما إذا كانت مفعلة أو معطلة افتراضيًا.
تؤدي الاستعلامات المصممة خصيصًا إلى استجابات مختلفة من منفذي خادم GraphQL للاستعلامات والطفرات والاشتراكات، مما يسهل التعرف على المحرك الخلفي والتمييز بين تطبيقات GraphQL المختلفة. (CWE: CWE-200)
يدعم graphw00f اكتشاف والتعرف على بصمة خوادم GraphQL التي تستخدم الاستعلامات القائمة على GET أو POST.
يحاول graphw00f حاليًا اكتشاف محركات GraphQL التالية:
يستخدم مشروع graphw00f مشروع مصفوفة تهديدات GraphQL كقاعدة بيانات مصفوفة الأمان للتكنولوجيا. عندما ينجح graphw00f في التعرف على بصمة نقطة نهاية GraphQL، سيقوم بطباعة مستند مصفوفة التهديدات. يساعد هذا المستند مهندسي الأمن في تحديد مدى نضج التكنولوجيا، وميزات الأمان التي تقدمها، وما إذا كانت تحتوي على أي ثغرات (CVEs).

git clone https://github.com/dolevf/graphw00f.git
Usage: main.py -d -f -t http://example.com
Options:
-h, --help show this help message and exit
-r, --noredirect Do not follow redirections given by 3xx responses
-t URL, --target=URL target url with the path
-f, --fingerprint fingerprint mode
-d, --detect detect mode
-p PROXY, --proxy=PROXY
HTTP(S) proxy URL in the form
http://user:pass@host:port
-T TIMEOUT, --timeout=TIMEOUT
Request timeout in seconds
-o OUTPUT_FILE, --output-file=OUTPUT_FILE
Output results to a file (CSV)
-l, --list List all GraphQL technologies graphw00f is able to
detect
-u USERAGENT, --user-agent=USERAGENT
Custom user-agent to use (overrides the one from
headers configuration)
-H HEADER, --header=HEADER
Custom headers to send (e.g. "Authorization: Bearer
ey...").
-w WORDLIST, --wordlist=WORDLIST
Path to a list of custom GraphQL endpoints
-v, --version Print out the current version and exit.
لا توجد الكثير من الإعدادات المطلوبة لـ graphw00f. ولكن، إذا كنت بحاجة إلى أشياء مثل رؤوس التفويض (Authorization) أو الكوكيز (Cookies) لنقطة نهاية معينة، استخدم ملف conf.py.
# Custom Headers
HEADERS = {'User-Agent':'graphw00f'}
# Custom Cookies
COOKIES = {"PHPSESS":"DEADBEEF"}
باستخدام --user-agent يتم إضافة مفتاح User-Agent بغض النظر عما إذا كان ملف conf.py يحتوي عليه أم لا، وإذا كان الملف يحتوي عليه بالفعل، فإن معلمة سطر الأوامر تلغيه.
هذا مثال لكيفية التعرف على البصمة (-f) لنقطة نهاية يكون موقع GraphQL معروفًا مسبقًا (/graphql)
python3 main.py -f -t https://demo.hypergraphql.org:8484/graphql
+-------------------+
| graphw00f |
+-------------------+
*** ***
** ***
** **
+--------------+ +--------------+
| Node X | | Node Y |
+--------------+ +--------------+
*** ***
** **
** **
+------------+
| Node Z |
+------------+
graphw00f - v1.0.7
The fingerprinting tool for GraphQL
Dolev Farhi <[email protected]>
[*] Checking if GraphQL is available at https://demo.hypergraphql.org:8484/graphql...
[*] Found GraphQL...
[*] Attempting to fingerprint...
[*] Discovered GraphQL Engine: (HyperGraphQL)
[!] Attack Surface Matrix: https://github.com/dolevf/graphw00f/blob/main/docs/hypergraphql.md
[!] Technologies: Java
[!] Homepage: https://www.hypergraphql.org
[*] Completed.
هذا مثال لكيفية اكتشاف graphw00f (-d) لمكان وجود GraphQL ثم تنفيذ عملية التعرف على البصمة (-f).
python3 main.py -f -d -t http://localhost:5000
+-------------------+
| graphw00f |
+-------------------+
*** ***
** ***
** **
+--------------+ +--------------+
| Node X | | Node Y |
+--------------+ +--------------+
*** ***
** **
** **
+------------+
| Node Z |
+------------+
graphw00f - v1.1.2
The fingerprinting tool for GraphQL
Dolev Farhi <[email protected]>
[*] Checking http://dvga.example.local:5000/graphql
[!] Found GraphQL at http://dvga.example.local:5000/graphql
[*] Attempting to fingerprint...
[*] Discovered GraphQL Engine: (Graphene)
[!] Attack Surface Matrix: https://github.com/nicholasaleks/graphql-threat-matrix/blob/master/implementations/graphene.md
[!] Technologies: Python
[!] Homepage: https://graphene-python.org
[*] Completed.
أي مشاكل مع graphw00f مثل النتائج الإيجابية الخاطئة، الاكتشافات غير الدقيقة، الأخطاء، إلخ. يرجى إنشاء مشكلة على GitHub مع تفاصيل البيئة.
هل تريد معرفة المزيد عن GraphQL؟ تفضل بزيارة مشروعي الآخر واخترق GraphQL: تطبيق GraphQL الضعيف القابل للاختراق