Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Wifi-p2p with NetworkManager
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
skiwarz
Apprentice
Apprentice


Joined: 23 Feb 2014
Posts: 267

PostPosted: Fri Oct 18, 2024 3:22 am    Post subject: Wifi-p2p with NetworkManager Reply with quote

I'm trying to set up a wifi direct connection between my laptop and an android phone. Searching online, this seems to be a very rare thing to do... For my laptop, I'm using NetworkManager with wpa_supplicant. My USE flags are:
Code:
net-wireless/wpa_supplicant-2.10-r4::gentoo was built with the following:
USE="dbus fils hs2-0 mbo mesh p2p readline -ap -broadcom-sta -eap-sim -eapol-test -fasteap -macsec -privsep (-ps3) -qt5 (-selinux) -smartcard -tdls -tkip -uncommon-eap-types -wep (-wimax) -wps" ABI_X86="(64)"

net-misc/networkmanager-1.46.0-r1::gentoo was built with the following:
USE="bluetooth concheck connection-sharing elogind gtk-doc introspection modemmanager nftables nss policykit tools wifi -audit -debug -dhclient -dhcpcd -gnutls -iptables -iwd -libedit -ofono -ovs -ppp -psl -resolvconf (-selinux) -syslog -systemd -teamd -test -vala -wext" ABI_X86="(64) -32 (-x32)"
FEATURES="fixlafiles unmerge-orphans news assume-digests binpkg-logs buildpkg-live sfperms usersync userpriv xattr ipc-sandbox strict pid-sandbox pkgdir-index-trusted parallel-fetch binpkg-docompress protect-owned preserve-libs config-protect-if-modified ebuild-locks multilib-strict network-sandbox userfetch unmerge-logs unknown-features-warn merge-sync qa-unresolved-soname-deps sandbox usersandbox binpkg-dostrip distlocks"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-z,pack-relative-relocs -Wl,--undefined-version"
I set up a connection using:
Code:
nmcli con add connection.id myp2pnetwork connection.type "wifi-p2p" wifi-p2p.peer $PEER_MAC_ADDRESS
When I start the connection with "nmcli con up myp2pnetwork" the terminal pauses for about 10 seconds before giving me "Error: Connection activation failed: The Wi-Fi P2P peer could not be found"
On the android device, I can see my laptop's wifi direct connection, and attempting to connect prompts me for a PIN.
1. How do I specify a PIN here, or is something breaking in my connection beforehand?
2. That error leads me to believe I *may* have the wrong MAC address. Is it possible to specify "connect to any MAC" on my laptop? I'm not sure if MAC randomization is on or causing issues on the android device (separate issue).
3. Should I be using different software for this, other than NetworkManager?
4. Does anyone actually use wifi direct and/or know anything about it? Like I said, the interwebs seems very... light... on the topic.
Thank you!
Back to top
View user's profile Send private message
Banana
Moderator
Moderator


Joined: 21 May 2004
Posts: 1730
Location: Germany

PostPosted: Fri Oct 18, 2024 5:41 am    Post subject: Reply with quote

I don't use it but I've found this german page which does it with wpa and android: https://jo-so.de/2020-04/Wifi-Direct.html
And also another one: https://kasiviswanathanblog.wordpress.com/wifi-p2p-in-linux/

Does your hardware support wifi direct / p2p ?
_________________
Forum Guidelines

PFL - Portage file list - find which package a file or command belongs to.
My delta-labs.org snippets do expire
Back to top
View user's profile Send private message
niderecha
n00b
n00b


Joined: 10 Nov 2024
Posts: 12

PostPosted: Sun Nov 10, 2024 11:43 pm    Post subject: Reply with quote

deleted, was a mistake

Last edited by niderecha on Mon Nov 11, 2024 8:59 am; edited 1 time in total
Back to top
View user's profile Send private message
Banana
Moderator
Moderator


Joined: 21 May 2004
Posts: 1730
Location: Germany

PostPosted: Mon Nov 11, 2024 8:19 am    Post subject: Reply with quote

niderecha wrote:
Thanks. There's no wifi at the moment, the test subject is a qemu virtial machine

I suspect you have answerd to the wrong topic?
_________________
Forum Guidelines

PFL - Portage file list - find which package a file or command belongs to.
My delta-labs.org snippets do expire
Back to top
View user's profile Send private message
niderecha
n00b
n00b


Joined: 10 Nov 2024
Posts: 12

PostPosted: Mon Nov 11, 2024 9:11 am    Post subject: Reply with quote

Oh yes, sorry. Damn
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum