Re: Looking for Mini PCI Express wireless card suggestions

2015-01-04 Thread Tom Van Looy
I think the cheapest (Wireless-N 2230) is ok because they all are 300
Mbit/s and OpenBSD doesn't support bluetooth.

And you would recommend iwn and not something else?

On Mon, Jan 5, 2015 at 8:00 AM, Stefan Sperling s...@stsp.name wrote:

 On Sun, Jan 04, 2015 at 11:27:54PM +0100, Tom Van Looy wrote:
  Hi
 
  My laptop (HP ProBook 6560b) has a Broadcom BCM4313 wifi card. Seems like
  it's not supported (there is also a thread on misc@ about this card).
 
  I want to buy a new card. What mini PCI express card is the best card you
  can buy?
 
  For example, there are a lot of cards in the iwn driver. I can buy a
 Intel
  Centrino Ultimate-N 6300 or Intel Centrino Advanced-N 6235 for around
 30
  euro, but I can also buy a Intel Centrino Wireless-N 2230 for 13 euro

 Any of the above should work with iwn(4). I'd suggest to get one of these,
 whichever matches your budget and requirements best.

 Note that some laptop brands have an artificial limitation where they
 refuse to boot if the wireless card has a PCI ID unknown to the BIOS.
 Not sure if this is a problem with HP but Lenovo Thinkpads do have this
 problem. In these cases the card needs to be compatible with both the
 laptop and OpenBSD.

  or something non Intel like Realtek RTL8192CE for 20 euro.

 This Realtek PCI card is not supported yet. Its USB dongle cousins are
 supported by urtwn(4). But the PCI ones don't work, unfortunately.

  They all should be supported, but I'm not sure what to expect. Any
  suggestions?
 
  Kind regards,
 
  Tom



PRG airport in misc

2015-01-04 Thread Jan Stary
The PRG airport has been renamed
in honor of Vaclav Havel quite some time ago.

Jan

Index: airport
===
RCS file: /cvs/src/share/misc/airport,v
retrieving revision 1.45
diff -u -p -r1.45 airport
--- airport 29 Dec 2014 20:16:58 -  1.45
+++ airport 4 Jan 2015 11:06:48 -
@@ -1339,7 +1339,7 @@ PPT:Pape'ete, Tahiti, French Polynesia
 PQI:Presque Isle, Maine, USA
 PQQ:Port Macquarie, New South Wales, Australia
 PRC:Prescott, Arizona, USA
-PRG:Ruzyne, Prague, Czech Republic
+PRG:Vaclav Havel Airport, Prague, Czech Republic
 PRI:Praslin Island, Seychelles
 PSA:G Galilei, Pisa, Italy
 PSE:Mercedita, Ponce, Puerto Rico, USA



Former Yugoslavia in countrycodes

2015-01-04 Thread Jan Stary
The breakup of Yugoslavia seems to be incomplete in countrycodes.
AFAIK, Kosovo does not have a country code assigned.

Jan


Index: countrycodes
===
RCS file: /cvs/src/share/misc/countrycodes,v
retrieving revision 1.3
diff -u -p -r1.3 countrycodes
--- countrycodes12 Oct 2002 02:14:15 -  1.3
+++ countrycodes4 Jan 2015 11:55:11 -
@@ -1,4 +1,4 @@
-# $OpenBSD: countrycodes,v 1.3 2002/10/12 02:14:15 jsyn Exp $
+# $OpenBSD: countrycodes,v 1.1 2015/01/04 10:58:19 hans Exp $
 #
 # ISO 3166-1 country names and code elements
 # http://www.din.de/gremien/nas/nabd/iso3166ma/codlstp1/en_listp1.html
@@ -141,9 +141,10 @@ LY:LIBYAN ARAB JAMAHIRIYA
 MA:MOROCCO
 MC:MONACO
 MD:MOLDOVA, REPUBLIC OF
+ME:MONTENEGRO
 MG:MADAGASCAR
 MH:MARSHALL ISLANDS
-MK:MACEDONIA, THE FORMER YUGOSLAV REPUBLIC OF
+MK:MACEDONIA
 ML:MALI
 MM:MYANMAR
 MN:MONGOLIA
@@ -189,6 +190,7 @@ PY:PARAGUAY
 QA:QATAR
 RE:REUNION
 RO:ROMANIA
+RS:SERBIA
 RU:RUSSIAN FEDERATION
 RW:RWANDA
 SA:SAUDI ARABIA
@@ -243,7 +245,6 @@ WF:WALLIS AND FUTUNA
 WS:SAMOA
 YE:YEMEN
 YT:MAYOTTE
-YU:YUGOSLAVIA
 ZA:SOUTH AFRICA
 ZM:ZAMBIA
 ZW:ZIMBABWE



Re: PRG airport in misc

2015-01-04 Thread Reyk Floeter
On Sun, Jan 04, 2015 at 12:08:44PM +0100, Jan Stary wrote:
 The PRG airport has been renamed
 in honor of Vaclav Havel quite some time ago.
 
   Jan
 

Thanks, done.

 Index: airport
 ===
 RCS file: /cvs/src/share/misc/airport,v
 retrieving revision 1.45
 diff -u -p -r1.45 airport
 --- airport   29 Dec 2014 20:16:58 -  1.45
 +++ airport   4 Jan 2015 11:06:48 -
 @@ -1339,7 +1339,7 @@ PPT:Pape'ete, Tahiti, French Polynesia
  PQI:Presque Isle, Maine, USA
  PQQ:Port Macquarie, New South Wales, Australia
  PRC:Prescott, Arizona, USA
 -PRG:Ruzyne, Prague, Czech Republic
 +PRG:Vaclav Havel Airport, Prague, Czech Republic
  PRI:Praslin Island, Seychelles
  PSA:G Galilei, Pisa, Italy
  PSE:Mercedita, Ponce, Puerto Rico, USA
 

-- 



Re: Former Yugoslavia in countrycodes

2015-01-04 Thread Milun Rajkovic
Because it's not a country (Kosovo). Btw it uses mobile networks of Monaco
or Luxembour or something like that, and landlines (and call number +381)
from Serbian infrastructure. Macedonia is also having an issue regarding
that. Messed up situation that won't settle any time soon.

On Sun, Jan 4, 2015 at 12:58 PM, Jan Stary h...@stare.cz wrote:

 The breakup of Yugoslavia seems to be incomplete in countrycodes.
 AFAIK, Kosovo does not have a country code assigned.

 Jan


 Index: countrycodes
 ===
 RCS file: /cvs/src/share/misc/countrycodes,v
 retrieving revision 1.3
 diff -u -p -r1.3 countrycodes
 --- countrycodes12 Oct 2002 02:14:15 -  1.3
 +++ countrycodes4 Jan 2015 11:55:11 -
 @@ -1,4 +1,4 @@
 -# $OpenBSD: countrycodes,v 1.3 2002/10/12 02:14:15 jsyn Exp $
 +# $OpenBSD: countrycodes,v 1.1 2015/01/04 10:58:19 hans Exp $
  #
  # ISO 3166-1 country names and code elements
  # http://www.din.de/gremien/nas/nabd/iso3166ma/codlstp1/en_listp1.html
 @@ -141,9 +141,10 @@ LY:LIBYAN ARAB JAMAHIRIYA
  MA:MOROCCO
  MC:MONACO
  MD:MOLDOVA, REPUBLIC OF
 +ME:MONTENEGRO
  MG:MADAGASCAR
  MH:MARSHALL ISLANDS
 -MK:MACEDONIA, THE FORMER YUGOSLAV REPUBLIC OF
 +MK:MACEDONIA
  ML:MALI
  MM:MYANMAR
  MN:MONGOLIA
 @@ -189,6 +190,7 @@ PY:PARAGUAY
  QA:QATAR
  RE:REUNION
  RO:ROMANIA
 +RS:SERBIA
  RU:RUSSIAN FEDERATION
  RW:RWANDA
  SA:SAUDI ARABIA
 @@ -243,7 +245,6 @@ WF:WALLIS AND FUTUNA
  WS:SAMOA
  YE:YEMEN
  YT:MAYOTTE
 -YU:YUGOSLAVIA
  ZA:SOUTH AFRICA
  ZM:ZAMBIA
  ZW:ZIMBABWE



Re: Former Yugoslavia in countrycodes

2015-01-04 Thread Dmitrij D. Czarkoff
Jan Stary said:
 -MK:MACEDONIA, THE FORMER YUGOSLAV REPUBLIC OF
 +MK:MACEDONIA

AFAIK the former variant is currently the correct one. There is a
dispute between Macedonia and Greece regarding the meaning of the word
Macedonia - Greece maintains that this word refers to its region (as
in Alexander III of Macedon).

-- 
Dmitrij D. Czarkoff



Re: Former Yugoslavia in countrycodes

2015-01-04 Thread Raf
On Sun, Jan 04, 2015 at 09:09:50AM EST, Dmitrij D. Czarkoff wrote:

 Jan Stary said:
  -MK:MACEDONIA, THE FORMER YUGOSLAV REPUBLIC OF
  +MK:MACEDONIA
 
 AFAIK the former variant is currently the correct one. There is a
 dispute between Macedonia and Greece regarding the meaning of the word
 Macedonia - Greece maintains that this word refers to its region (as
 in Alexander III of Macedon).

TFYROM is the name, under which, Republic of Macedonia (to give its
full name) is, provisionally, referred to within the UN, until said
dispute is resolved[0]. Therefore, given that ISO 3166-1 country codes
and names are linked to membership within the UN, or other international
organisations, the former name should remain... or changed to:

MK:MACEDONIA, REPUBLIC OF

to find the middle ground.

[0] http://www.un.org/en/members/index.shtml#t

Regards,

Raf



Re: is what this guy is saying even anywhere close to reasonable, about ssh everywhere?

2015-01-04 Thread Johan Beisser
no.

Sent form my iFoe. 

 On Jan 4, 2015, at 05:34, bofh goodb...@gmail.com wrote:
 
 https://medium.com/@shazow/ssh-how-does-it-even-9e43586e4ffc
 
 -- 
 http://www.glumbert.com/media/shift
 http://www.youtube.com/watch?v=tGvHNNOLnCk
 This officer's men seem to follow him merely out of idle curiosity.  --
 Sandhurst officer cadet evaluation.
 Securing an environment of Windows platforms from abuse - external or
 internal - is akin to trying to install sprinklers in a fireworks factory
 where smoking on the job is permitted.  -- Gene Spafford
 learn french:  http://www.youtube.com/watch?v=30v_g83VHK4



Strange behaviour in dd swab conversion

2015-01-04 Thread Martin Wolters

Hi,

I was playing around with dd today and noticed something strange. The
specification[1] states:

 If the swab conversion is specified, each pair of input data bytes
 shall be swapped. If there is an odd number of bytes in the input
 block, the last byte in the input record shall not be swapped.

The OpenBSD man page similarly says:

 Swap every pair of input bytes. If an input buffer has an odd number
 of bytes, the last byte will be ignored during swapping.

I understand this to mean that if ibs is set to an odd value, every
ibs'th byte in the output file keeps the value from the input file.
Similarly with partial blocks of odd length.

I created a file with the following contents (59 bytes, including the
newline at the end):
 Hi! I have 3 words for you. Just kidding, there were more.

And ran dd on it like this:
 $ dd if=atextfile.txt of=swap.txt ibs=11 conv=swab
 5+1 records in
 0+1 records out
 4 odd length swab blocks
 59 bytes transferred in 0.000 secs (1053571 bytes/sec)

I would have expected dd to report 5 odd length blocks here. When view-
ing the result in hexdump, I found the byte at offset 0xA to be the
same as in the original file, but at 0x15, 0x20, 0x2B and 0x36, they
are replaced by the value 0.

Checking other implementations, I found FreeBSD's dd to give the exact
result I expected (5 odd length swab blocks and the original bytes at
the aforementioned offsets) and GNU not even trying to adhere to any
sensible interpretation of the specification (swapping between border-
ing blocks and all over the place).

English is not my native language, so maybe there is ambiguity in the
specification, which I failed to pick up. But I thought it might be a
bug, so I decided to report my observation.

Have a good time,
Martin

[1] http://pubs.opengroup.org/onlinepubs/9699919799/utilities/dd.html



Re: MEDION S4222 UMTS stick not recognized

2015-01-04 Thread Ingo Feinerer
On Fri, Jan 02, 2015 at 12:26:53PM +0100, Ingo Feinerer wrote:
 a MEDION S4222 UMTS (https://www.hot.at/images/medion_usb_stick.png) stick
 
 port 2 addr 4: high speed, power 500 mA, config 1, Product(0x0002), MediaTek 
 Inc(0x0e8d), rev 3.00, iSerialNumber 683694200024400
 
 attaches as CDROM
 
 umass0 at uhub7 port 2 configuration 1 interface 0 MediaTek Inc Product rev 
 2.00/3.00 addr 4
 umass0: using SCSI over Bulk-Only
 scsibus4 at umass0: 2 targets, initiator 0
 cd0 at scsibus4 targ 1 lun 0: MEDIATEK, FLASH DISK, 6225 SCSI0 5/cdrom 
 removable serial.0e8d0002694200024400
 
 but the logic is missing to switch to modem mode.
 
 I tried various combinations via sys/dev/usb/umsm.c but did not manage
 to get ucom attached.

I am now able to switch the device into modem mode with the diff below
(the constants are derived from the
http://www.draisberghof.de/usb_modeswitch/ data package for the device
with vendor 0x0e8d and product 0x0002).

After the switch several new devices attach:

umsm0 at uhub7 port 2 configuration 1 interface 0 MediaTek Inc Product rev 
2.00/3.00 addr 4
umsm0 detached
umsm0 at uhub7 port 2 configuration 1 interface 0 MediaTek Inc Product rev 
2.00/3.00 addr 4
umsm0: missing endpoint
umsm1 at uhub7 port 2 configuration 1 interface 1 MediaTek Inc. product 
0x00a5 rev 2.00/3.00 addr 4
umsm1: missing endpoint
umsm2 at uhub7 port 2 configuration 1 interface 2 MediaTek Inc. product 
0x00a5 rev 2.00/3.00 addr 4
ucom0 at umsm2
umsm3 at uhub7 port 2 configuration 1 interface 3 MediaTek Inc. product 
0x00a5 rev 2.00/3.00 addr 4
ucom1 at umsm3
umsm4 at uhub7 port 2 configuration 1 interface 4 MediaTek Inc. product 
0x00a5 rev 2.00/3.00 addr 4
ucom2 at umsm4
umsm5 at uhub7 port 2 configuration 1 interface 5 MediaTek Inc. product 
0x00a5 rev 2.00/3.00 addr 4
ucom3 at umsm5
umass0 at uhub7 port 2 configuration 1 interface 6 MediaTek Inc. product 
0x00a5 rev 2.00/3.00 addr 4
umass0: using SCSI over Bulk-Only
scsibus4 at umass0: 2 targets, initiator 0

According to
http://www.draisberghof.de/usb_modeswitch/bb/viewtopic.php?f=3t=2006
interface 2 (= ucom0 at umsm2) should work as serial modem. However, I
always have an input/output error:

$ sudo cu -l cuaU0
cu: open(/dev/cuaU0): Input/output error

(the same for all cuaU[0-3]).

Any ideas for further investigation?

Best regards,
Ingo

Index: src/sys/dev/usb/umsm.c
===
RCS file: /cvs/src/sys/dev/usb/umsm.c,v
retrieving revision 1.100
diff -u -p -r1.100 umsm.c
--- src/sys/dev/usb/umsm.c  12 Jul 2014 21:24:33 -  1.100
+++ src/sys/dev/usb/umsm.c  4 Jan 2015 08:22:51 -
@@ -109,8 +109,9 @@ struct umsm_type {
 #defineDEV_UMASS5  0x0100
 #defineDEV_UMASS6  0x0200
 #defineDEV_UMASS7  0x0400
+#defineDEV_UMASS8  0x1000
 #define DEV_UMASS  (DEV_UMASS1 | DEV_UMASS2 | DEV_UMASS3 | DEV_UMASS4 | \
-DEV_UMASS5 | DEV_UMASS6 | DEV_UMASS7)
+DEV_UMASS5 | DEV_UMASS6 | DEV_UMASS7 | DEV_UMASS8)
 };
 
 static const struct umsm_type umsm_devs[] = {
@@ -154,6 +155,9 @@ static const struct umsm_type umsm_devs[
 
{{ USB_VENDOR_KYOCERA2, USB_PRODUCT_KYOCERA2_KPC650 }, 0},
 
+   {{ USB_VENDOR_MEDIATEK, 0x0002 }, DEV_UMASS8},
+   {{ USB_VENDOR_MEDIATEK, 0x00a5 }, 0},
+
/* XXX Some qualcomm devices are missing */
{{ USB_VENDOR_QUALCOMM, USB_PRODUCT_QUALCOMM_MSM_DRIVER }, DEV_UMASS1},
{{ USB_VENDOR_QUALCOMM, USB_PRODUCT_QUALCOMM_MSM_DRIVER2 }, DEV_UMASS4},
@@ -703,6 +707,13 @@ umsm_umass_changemode(struct umsm_softc 
cbw.bCBWFlags = CBWFLAGS_IN;
cbw.CBWCDB[0] = UMASS_SERVICE_ACTION_OUT;
cbw.CBWCDB[1] = 0x03;
+   break;
+   case DEV_UMASS8:
+   USETDW(cbw.dCBWDataTransferLength, 0x0);
+   cbw.bCBWFlags = CBWFLAGS_OUT;
+   cbw.CBWCDB[0] = 0xf0;
+   cbw.CBWCDB[1] = 0x01;
+   cbw.CBWCDB[2] = 0x03;
break;
default:
DPRINTF((%s: unknown device type.\n, sc-sc_dev.dv_xname));
Index: src/sys/dev/usb/usbdevs
===
RCS file: /cvs/src/sys/dev/usb/usbdevs,v
retrieving revision 1.641
diff -u -p -r1.641 usbdevs
--- src/sys/dev/usb/usbdevs 4 Dec 2014 10:41:42 -   1.641
+++ src/sys/dev/usb/usbdevs 4 Jan 2015 08:23:11 -
@@ -452,6 +452,7 @@ vendor CTC  0x0e5e  CONWISE Technology
 vendor HAWKING 0x0e66  Hawking
 vendor FOSSIL  0x0e67  Fossil
 vendor GMATE   0x0e7e  G.Mate
+vendor MEDIATEK0x0e8d  MediaTek Inc.
 vendor OTI 0x0ea0  Ours Technology
 vendor PILOTECH0x0eaf  Pilotech
 vendor NOVATECH0x0eb0  Nova Tech



dmesg
=

OpenBSD 5.7-beta (GENERIC) #10: Sat Jan  3 11:48:47 CET 2015
r...@blue.my.domain:/usr/src/sys/arch/amd64/compile/GENERIC
RTC BIOS diagnostic error 80clock_battery

Re: YP Alternative

2015-01-04 Thread David Gwynne
 On 4 Jan 2015, at 5:32 pm, Brian Empson br...@teamhandbanana.com wrote:
 
 This sounds interesting. What would you replace krb5 with, if you don't mind 
 me asking? I was contemplating krb5, but the setup and such is a pain for me 
 (because I am not familiar with it). I'll probably wind up rolling something 
 custom with LDAP and YP mappings thrown in.

i dunno. ideally i would just do basic auth over https against something that 
just returns 200 or 403. bsdauth on openbsd means i could probably implement 
that with a crappy script. linux probably has a crazy pam module i could use to 
do auth with http, but the solarish things i run almost certainly dont.

however, linux and solaris still support krb5 auth out of the box, so its only 
a problem i really have to solve on openbsd. or use ldap auth.

 
 On 1/4/2015 2:26 AM, David Gwynne wrote:
 On 2 Jan 2015, at 9:52 pm, Brian Empson br...@teamhandbanana.com wrote:
 
 I'm looking into a way to sync up group and user information across a 
 network of OpenBSD machines. I like YP, except that I don't need the 
 password hashes transferred across the network. I like that it's built 
 right into the base install, are there better ways to handle synchronizing 
 login details across multiple machines that is built into the base install? 
 Preferably written by the OpenBSD team, too?
 while not directly answering your question, i can say openbsd can do this 
 kind of stuff without yp on the wire.
 
 at work i use ypldap to get user/group information from active directory. we 
 populate the rfc2307 attributes on our users and groups to make them useful 
 on unix systems. we use the single directory as a name service backend for 
 openbsd, solaris, linux, and windows (of course).
 
 we're still using krb5 for password authentication. i really have to fix 
 that.
 
 we've also augmented the AD schema to store users ssh keys in the directory 
 too. sshd gets access to them via AuthorizedKeysCommand and a perl script. 
 this allows ssh key based single sign on across all our unixish systems, 
 even if their home directories are not available on the system. this is 
 useful for providing services over ssh. an example of such a service we 
 provide is svn and git on a dedicated server. all our users are on the 
 system via ypldap, and they can auth using their own username and either a 
 password or ssh key.
 
 dlg



Re: httpd: multiple addresses for one server

2015-01-04 Thread Clint Sand
On Sat, Jan 03, 2015 at 12:39:06PM -0500, Geoff Steckel wrote:
 On 01/03/2015 08:42 AM, Reyk Floeter wrote:
 On Thu, Jan 01, 2015 at 11:54:46PM -0500, Geoff Steckel wrote:
 Is there any way todo the equivalent of:
 
 server an.example.com
  listen on 192.168.2.99
  listen on 2001.fefe.1.1::99
 
 ??
 It appears that the code in parse.y explicitly forbids this
 and the data structures for a server don't *seem*
 to have more than one slot for an address.
 
 Is there another way to achieve this effect?
  From one comment in the checkins, it looks like
 
 server an.example.com
  listen on 192.168.2.99
 .
 server an.example.com
  listen on 2001.fefe.1.1::99
 
 would work.
 
 Duplicating the entire server description is
 difficult to maintain.
 
 Is someone planning to work in this area soon?
 
 thanks
 Geoff Steckel
 
 I used include directives to avoid duplications (see previous reply)
 but the following diff allows to add aliases and multiple listen
 statements.
 
 Reyk
 
 [...diff omitted...]
 1000 thanks for an almost instantaneous and complete extension!!
 This makes httpd a complete replacement for apache in my host.
 
 Geoff Steckel

Just last night I dupilcated many virtual hosts and wished there
was an easy way to alias domain.foo to www.domain.foo. 

Thanks for the diff!



Re: is what this guy is saying even anywhere close to reasonable, about ssh everywhere?

2015-01-04 Thread FRIGN
On Sat, 3 Jan 2015 23:34:51 -0500
bofh goodb...@gmail.com wrote:

 https://medium.com/@shazow/ssh-how-does-it-even-9e43586e4ffc

No, because this dude obviously does not understand UDP.
SSH can be quite useful to run some services behind it,
but you quickly get latency issues (hell, it even is
a pain using the chat-client) and SSH is not a protocl
I would call really optimal or desirable for such a
task, let alone replacing HTTP/2.
Read this[0] for a short discourse on it.

Cheers

FRIGN

[0]: http://harmful.cat-v.org/software/ssh

-- 
FRIGN d...@frign.de



Re: OpenBSD + OptiPlex 320 = frozen clock?

2015-01-04 Thread Jonathon Sisson
On Fri, Jan 02, 2015 at 10:47:02AM -0500, John Merriam wrote:
 Hello.  I have a strange issue with OpenBSD on my Dell OptiPlex 320.  The
 clock doesn't move:
 
 # date; sleep 55; date
 Thu Jan  1 02:25:47 EST 2015
 Thu Jan  1 02:25:47 EST 2015


# sysctl kern.timecounter.choice

I have a Dell that has a broken clocksource that exhibits the same.
Set kern.timecounter.choice to one of the other choices (you'll have 
to experiment with that, I can't help you there).  Once you find the
one that works, set it in /etc/sysctl.conf and be on your way.



Re: OpenBSD + OptiPlex 320 = frozen clock?

2015-01-04 Thread Jonathon Sisson
On Sun, Jan 04, 2015 at 01:23:24PM -0500, Jonathon Sisson wrote:
 # sysctl kern.timecounter.choice
 
 I have a Dell that has a broken clocksource that exhibits the same.
 Set kern.timecounter.choice to one of the other choices (you'll have 
 to experiment with that, I can't help you there).  Once you find the
 one that works, set it in /etc/sysctl.conf and be on your way.
 

As already pointed out, that should have been set kern.timecounter.hardware
using one of the kern.timecounter.choice options



Re: PRG airport in misc

2015-01-04 Thread Zeljko Jovanovic

On 04.01.2015. 14:22, Reyk Floeter wrote:


Thanks, done.


Index: airport



Speaking of changed airport names, I expected to see:

BEG:Surcin, Belgrade, Yugoslavia

but it was apparently never entered at all.

The current name is:

BEG:Nikola Tesla, Belgrade, Serbia

and there are another few missing:

INI:Constantine the Great, Nis, Serbia
ZZE:Ponikve, Uzice, Serbia
KVO:Morava, Kraljevo, Serbia


These two:

TIV:Tivat, Yugoslavia
TGD:Golubovci, Podgorica, Yugoslavia

should be changed to:

TIV:Tivat, Montenegro
TGD:Golubovci, Podgorica, Montenegro



Re: PRG airport in misc

2015-01-04 Thread Joshua Smith
Just curious how this airport database came to be and why is it included in the 
base system. 

It struck me as kind of unusual but perhaps there is something of historical 
significance I am missing with regards to its inclusion. 

--
Josh Smith

Sent from my iPhone. 

 On Jan 4, 2015, at 1:30 PM, Zeljko Jovanovic zelj...@tesla.rcub.bg.ac.rs 
 wrote:
 
 On 04.01.2015. 14:22, Reyk Floeter wrote:
 
 Thanks, done.
 
 Index: airport
 
 
 Speaking of changed airport names, I expected to see:
 
 BEG:Surcin, Belgrade, Yugoslavia
 
 but it was apparently never entered at all.
 
 The current name is:
 
 BEG:Nikola Tesla, Belgrade, Serbia
 
 and there are another few missing:
 
 INI:Constantine the Great, Nis, Serbia
 ZZE:Ponikve, Uzice, Serbia
 KVO:Morava, Kraljevo, Serbia
 
 
 These two:
 
 TIV:Tivat, Yugoslavia
 TGD:Golubovci, Podgorica, Yugoslavia
 
 should be changed to:
 
 TIV:Tivat, Montenegro
 TGD:Golubovci, Podgorica, Montenegro



Re: Strange behaviour in dd swab conversion

2015-01-04 Thread Ted Unangst
On Sun, Jan 04, 2015 at 18:44, Martin Wolters wrote:

 I would have expected dd to report 5 odd length blocks here. When view-
 ing the result in hexdump, I found the byte at offset 0xA to be the
 same as in the original file, but at 0x15, 0x20, 0x2B and 0x36, they
 are replaced by the value 0.
 
 Checking other implementations, I found FreeBSD's dd to give the exact
 result I expected (5 odd length swab blocks and the original bytes at
 the aforementioned offsets) and GNU not even trying to adhere to any
 sensible interpretation of the specification (swapping between border-
 ing blocks and all over the place).

Indeed. Without further commenting on how silly I think the swab
feature is (let alone the name), the argument to the swapbytes
function is incorrect. We should be using the recently read count, not
the total read count.

Index: dd.c
===
RCS file: /cvs/src/bin/dd/dd.c,v
retrieving revision 1.19
diff -u -p -r1.19 dd.c
--- dd.c11 Dec 2014 20:39:06 -  1.19
+++ dd.c4 Jan 2015 18:37:21 -
@@ -304,7 +304,7 @@ dd_in(void)
}
 
if (ddflags  C_SWAB) {
-   if ((n = in.dbcnt)  1) {
+   if ((n = in.dbrcnt)  1) {
++st.swab;
--n;
}



Re: PRG airport in misc

2015-01-04 Thread Paolo Aglialoro
There are plans to use obsd for IATA servers...
Il 04/gen/2015 19:39 Joshua Smith juice...@gmail.com ha scritto:

 Just curious how this airport database came to be and why is it included
 in the base system.

 It struck me as kind of unusual but perhaps there is something of
 historical significance I am missing with regards to its inclusion.

 --
 Josh Smith

 Sent from my iPhone.

  On Jan 4, 2015, at 1:30 PM, Zeljko Jovanovic 
 zelj...@tesla.rcub.bg.ac.rs wrote:
 
  On 04.01.2015. 14:22, Reyk Floeter wrote:
 
  Thanks, done.
 
  Index: airport
 
 
  Speaking of changed airport names, I expected to see:
 
  BEG:Surcin, Belgrade, Yugoslavia
 
  but it was apparently never entered at all.
 
  The current name is:
 
  BEG:Nikola Tesla, Belgrade, Serbia
 
  and there are another few missing:
 
  INI:Constantine the Great, Nis, Serbia
  ZZE:Ponikve, Uzice, Serbia
  KVO:Morava, Kraljevo, Serbia
 
 
  These two:
 
  TIV:Tivat, Yugoslavia
  TGD:Golubovci, Podgorica, Yugoslavia
 
  should be changed to:
 
  TIV:Tivat, Montenegro
  TGD:Golubovci, Podgorica, Montenegro



Re: httpd: multiple addresses for one server

2015-01-04 Thread jungle Boogie
Hi Clint, Geoff,
On 4 January 2015 at 10:14, Clint Sand clint@incidentresponse.services wrote:
 On Sat, Jan 03, 2015 at 12:39:06PM -0500, Geoff Steckel wrote:
 1000 thanks for an almost instantaneous and complete extension!!
 This makes httpd a complete replacement for apache in my host.

 Geoff Steckel

 Just last night I dupilcated many virtual hosts and wished there
 was an easy way to alias domain.foo to www.domain.foo.

 Thanks for the diff!


Consider donating to the foundation[0] to ensure this work continues!


[0] http://www.openbsdfoundation.org/donations.html

-- 
---
inum: 883510009027723
sip: jungleboo...@sip2sip.info
xmpp: jungle-boo...@jit.si



Re: YP Alternative

2015-01-04 Thread Jiri B
On Sun, Jan 04, 2015 at 06:40:09PM +1000, David Gwynne wrote:
 i dunno. ideally i would just do basic auth over https against something that 
 just returns 200 or 403. bsdauth on openbsd means i could probably implement 
 that with a crappy script. linux probably has a crazy pam module i could use 
 to do auth with http, but the solarish things i run almost certainly dont.

Did you mean this as SSO solution?

j.



Re: PRG airport in misc

2015-01-04 Thread Raf
On Sun, Jan 04, 2015 at 01:30:21PM EST, Zeljko Jovanovic wrote:

 Speaking of changed airport names, I expected to see:
 [...]

Don't expect, send a diff!

Raf



Re: Former Yugoslavia in countrycodes

2015-01-04 Thread Jiri B
On Sun, Jan 04, 2015 at 12:58:05PM +0100, Jan Stary wrote:

 -MK:MACEDONIA, THE FORMER YUGOSLAV REPUBLIC OF
 +MK:MACEDONIA

Not all Greeks will raise their voices :D

j.



Looking for Mini PCI Express wireless card suggestions

2015-01-04 Thread Tom Van Looy
Hi

My laptop (HP ProBook 6560b) has a Broadcom BCM4313 wifi card. Seems like
it's not supported (there is also a thread on misc@ about this card).

I want to buy a new card. What mini PCI express card is the best card you
can buy?

For example, there are a lot of cards in the iwn driver. I can buy a Intel
Centrino Ultimate-N 6300 or Intel Centrino Advanced-N 6235 for around 30
euro, but I can also buy a Intel Centrino Wireless-N 2230 for 13 euro or
something non Intel like Realtek RTL8192CE for 20 euro.

They all should be supported, but I'm not sure what to expect. Any
suggestions?

Kind regards,

Tom



Re: YP Alternative

2015-01-04 Thread David Gwynne
 On 5 Jan 2015, at 06:14, Jiri B ji...@devio.us wrote:
 
 On Sun, Jan 04, 2015 at 06:40:09PM +1000, David Gwynne wrote:
 i dunno. ideally i would just do basic auth over https against something 
 that just returns 200 or 403. bsdauth on openbsd means i could probably 
 implement that with a crappy script. linux probably has a crazy pam module i 
 could use to do auth with http, but the solarish things i run almost 
 certainly dont.
 
 Did you mean this as SSO solution?

which sso are you talking about? if you mean same sign-on, then yes. my users 
only have to know a single username and password on our infrastructure.



Re: Relayd, how to relay-to based on path

2015-01-04 Thread Harald Klimach
Hey,

thanks a lot for your kind reply, and sorry for this late answer.

 In the Paper Recent work in OpenBSD relayd from 2013 there is an
 example with: match request path /images relay-to 10.1.1.1
 Basically I need that and a second statement with
 match request path /app relay-to 10.1.1.2

 on case this was not answered yet:
 
 Use the following in your protocols section:
 
match request path /some/path/** forward to extratable
 
 You need something like
 
forward to extratable port www mode roundrobin \
check http / code 200 timeout 1000
 
 in your relay section as well.


This is great, it seems to work like a charm! My configuration now has two 
tables
defined rails and apache. In the protocols section, I have then

match request path /collab/** forward to rails
match request path /svn/** forward to apache
match request path /hg/** forward to apache

and in the relay section I got:

forward to apache port 
forward to rails port 8000

That was a nice holiday present, thank you!
Harald



ARM Firewall Hardware

2015-01-04 Thread Predrag Punosevac
I started entertain the idea of getting ARM based hardware for my new
home firewall.

Are there ARM based consumer motherboards with Gigabit lan controller
which can be used for home firewall hobby project? How close is armv7 or
any other OpenBSD version of being fully functional on such hardware?

Cheers,
Predrag



Re: Former Yugoslavia in countrycodes

2015-01-04 Thread Predrag Punosevac
On Sun, Jan 04, 2015 at 12:58:05PM +0100, Jan Stary wrote:
 AFAIK, Kosovo does not have a country code assigned.

Is that diff the best thing a wonna be OpenBSD developer can come up
after these long holidays? That is really sad. I could suggest you five
interesting things to hack on from the top of my head and I am just a
stupid mathematician.

For many of us who were born in that country and whose lives have been
altered forever by actual events on the ground your remark doesn't sound
clever but it is just a rude remainder of deceased parents, family
members, relatives, friends, and peaces of our own lives we have lost
during bloody break up.

Best,
Predrag



log options in httpd.conf

2015-01-04 Thread Clint Sand
Struggling with the behavior of the log options in httpd.conf on 5.6-stable. 

I'm trying to get different virtual domains to log to their own files but no
matter what option I've tried after reading the man page I get odd results. 

Using the configuration below, ALL access gets logged to the default access.log,
even the ones from the other servers listed. In the specific domain-access.log
files I get only the errors and nothing in the domain-error.log files. 

Can anyone look at the config below and help me understand why it might be
logging that way and how to fix it? 

Cheers, 

-Clint 


#
# Macros
#
ext_addr=egress
include /etc/nginx/mime.types

# A minimal default server
server default {
listen on $ext_addr port 80
directory { no index, index index.html, index index.php }

   log style combined

location *.php {
fastcgi socket /tmp/php-fpm.sock
}

}

server www.domain1.com {
listen on $ext_addr port 80
directory { no index, index index.html, index index.php }
   root /domain1.com/htdocs

log style combined
   log { access domain1.com-access.log, error domain1.com-error.log }

location *.php { fastcgi socket /tmp/php-fpm.sock } 
}

server domain1.com {
listen on $ext_addr port 80
directory { no index, index index.html, index index.php }
   root /domain1.com/htdocs

   log style combined
   log { access domain1.com-access.log, error domain1.com-error.log }

location *.php { fastcgi socket /tmp/php-fpm.sock }

}

server www.domain2.com {
listen on $ext_addr port 80
directory { no index, index index.html, index index.php }
   root /domain2.com/htdocs

   log style combined
   log { access domain2.com-access.log, error domain2.com-error.log }

location *.php { fastcgi socket /tmp/php-fpm.sock }

}



Re: ARM Firewall Hardware

2015-01-04 Thread Patrick Wildt
Until recently there has not been ARM hardware that actually has more
than two Gigabit Ethernet ports.  As of now there are two options:

There’s the Banana Pi R1, which basically is a bigger Banana Pi with
5 Gigabit Ports connected to a Broadcom BCM53125 Switch.

The BPI-R1, also called Lamobo R1 is based on an Allwinner A20.
There currently seems to be only minimal support for the SoC in
OpenBSD.

FreeScale has recently been working on ARM-based network chips.
They already had QorIQ network chips based on PowerPC and now
basically replaced the PPC core with an ARM one, keeping the „old“
peripherals.

They are be working on LS1 and LS2 SoCs of varying performance.
One of them is a dual-core Cortex A7, another one a Cortex A9,
a rather slow ARM11 and even a few ARM 64-bit cores.

As far as I know they already supply development boards[0] and
reference design[1] hardware for the LS1021A, the dual core Cortex A7.

That hardware is really interesting, but rather expensive and not
supported by OpenBSD.

\Patrick

[0]
http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=TWR-LS1021A
[1]
http://cache.freescale.com/files/32bit/doc/quick_ref_guide/LS1021A-IOTGS.pdf

On Sun, Jan 04, 2015 at 10:41:14PM -0500, Predrag Punosevac wrote:
 I started entertain the idea of getting ARM based hardware for my new
 home firewall.
 
 Are there ARM based consumer motherboards with Gigabit lan controller
 which can be used for home firewall hobby project? How close is armv7 or
 any other OpenBSD version of being fully functional on such hardware?
 
 Cheers,
 Predrag



Re: Looking for Mini PCI Express wireless card suggestions

2015-01-04 Thread Stefan Sperling
On Sun, Jan 04, 2015 at 11:27:54PM +0100, Tom Van Looy wrote:
 Hi
 
 My laptop (HP ProBook 6560b) has a Broadcom BCM4313 wifi card. Seems like
 it's not supported (there is also a thread on misc@ about this card).
 
 I want to buy a new card. What mini PCI express card is the best card you
 can buy?
 
 For example, there are a lot of cards in the iwn driver. I can buy a Intel
 Centrino Ultimate-N 6300 or Intel Centrino Advanced-N 6235 for around 30
 euro, but I can also buy a Intel Centrino Wireless-N 2230 for 13 euro 

Any of the above should work with iwn(4). I'd suggest to get one of these,
whichever matches your budget and requirements best.

Note that some laptop brands have an artificial limitation where they
refuse to boot if the wireless card has a PCI ID unknown to the BIOS.
Not sure if this is a problem with HP but Lenovo Thinkpads do have this
problem. In these cases the card needs to be compatible with both the
laptop and OpenBSD.

 or something non Intel like Realtek RTL8192CE for 20 euro.

This Realtek PCI card is not supported yet. Its USB dongle cousins are
supported by urtwn(4). But the PCI ones don't work, unfortunately.

 They all should be supported, but I'm not sure what to expect. Any
 suggestions?
 
 Kind regards,
 
 Tom