From owner-freebsd-questions@FreeBSD.ORG Wed Jun 10 19:05:47 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C24821065686 for ; Wed, 10 Jun 2009 19:05:47 +0000 (UTC) (envelope-from bahamasfranks@gmail.com) Received: from yw-out-2324.google.com (yw-out-2324.google.com [74.125.46.29]) by mx1.freebsd.org (Postfix) with ESMTP id 7FAC28FC1D for ; Wed, 10 Jun 2009 19:05:42 +0000 (UTC) (envelope-from bahamasfranks@gmail.com) Received: by yw-out-2324.google.com with SMTP id 9so530414ywe.13 for ; Wed, 10 Jun 2009 12:05:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=3JbWIcgQReuuK704bM1rtNMyImOIw0SiexVlzC/BQJ4=; b=VfCUXAtz6LMX+rhiHNsWFcPNJzZlBCvtocHakKB/ghoqFTCTNkWBdM4PR4zTnHUIki d26AdGJ7Um3+ygCD7GS13SZ7bQRV17qyKT1HYIdgmbFAtCeg3HbT8CauPRRu1dhLY5ZR DiNAXTNdrXHauSyW5U36bYhVe8LNIzfIYhUQ0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=wvj7pV0Kr/GWI2RftRl4ls1gLVCjS0cqffOBGyaEFYrHPcK2+Aa5GYbyfPwpu8dWHc ZtHdMrp0MGNKOFnDAIB9u9KnBzhRMAdc9V/E9XRG5uajz9I7RTR99iGDVo5YllsRuckd pXVeLPzKmuOQJ5xVSrrLEThFtSEP4yojuw5qU= MIME-Version: 1.0 Received: by 10.100.172.16 with SMTP id u16mr1750023ane.85.1244660738551; Wed, 10 Jun 2009 12:05:38 -0700 (PDT) Date: Wed, 10 Jun 2009 12:05:38 -0700 Message-ID: <539c60b90906101205g5c1281k34ed5b5c69666df4@mail.gmail.com> From: Steve Franks To: Roland Smith Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: FreeBSD Mailing List Subject: Re: ugen device no permissions for libusb [was: Re: devd or devfs for ucom?] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Jun 2009 19:05:48 -0000 >> While I wouldn't mind an answer to that question, it's actually >> working; however, my program that uses libftdi & libusb to talk to my >> ugen still needs to run as sudo to see the device - but if I run chmod >> 666 /dev/* (which I'm sure is a bad idea), I don't need sudo; what >> device is required for libusb besides ugen? =A0The hub? > > It will need access to /dev/usb* > > My solution was to create a group called 'usb', adding my user-id as a > member, and set that as the group of /dev/usb*, with permissions 0660: > > ------- /etc/devfs.rules excerpt ------- > [myrules=3D10] > add path 'uscanner*' mode 0660 group usb > add path 'usb*' mode 0660 group usb > add path 'ugen*' mode 0660 group usb > ------- /etc/devfs.rules excerpt ------- > > ------- /etc/rc.conf excerpt ------- > # Set the default devfs ruleset. > devfs_system_ruleset=3D"myrules" > ------- /etc/rc.conf excerpt ------- Ah! Perfect, that was the ticket - I didn't have permissions for the usb device, even though I had permissions for ugen. Should've occurred to me sooner. Been running it under sudo for a few weeks now... Thanks, Roland, Steve