עבור לתוכן
View in the app

A better way to browse. Learn more.

HWzone

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Mac Address code in Python

Featured Replies

פורסם

התחלתי לכתוב קודים בפייטון אבל רציתי להגיע עם זה יותר לרמה של פיתוח כלי איסוף מידע מאשר פיתוח רגיל, הקוד שלי לשינוי mac address, אשמח לקבל עצות לשיפור הקוד.

 

import subprocess
import optparse

def get_arg():
    opt = optparse.OptionParser()
    opt.add_option("-i", "--interface", dest="interface", help="This sets the interface")
    opt.add_option("-m", "--mac", dest="mac", help="This sets the MAC address")
    return opt.parse_args()


def change_MAC(interface, mac):

    print("[+] Changing the MAC address for", interface, "for MAC", mac)
    subprocess.call(["ifconfig", interface, "down"])
    subprocess.call(["ifconfig", interface, "hw", "ether", mac])
    subprocess.call(["ifconfig", interface, "up"])


(options, arg) = get_arg()
change_MAC(options.interface, options.mac)

 

ארכיון

דיון זה הועבר לארכיון ולא ניתן להוסיף בו תגובות חדשות.

דיונים חדשים

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.