I tried searching online but can't seem to find whether or not OpenSSL support both NamedCurve.arbitrary_explicit_prime_curves and NamedCurve.arbitrary_explicit_char2_curves? As far as I can tell bouncy castle are the only SSL/TLS implementation that supports it, any others that anyone known of?
The code for arbitrary curves is in the library; see the source code, file
crypto/ec/ec_lcl.h, in particular function
ec_GFp_simple_group_set_curve(). The OpenSSL code includes specialized function for some specific curves (in particular NIST curves) but also has functions for the general case.
Code for encoding and decoding arbitrary curve parameters in ASN.1 (e.g. for use with a public key in an X.509 certificate) also appears to be present (in
crypto/ec/ec_asn1.c). However, I doubt this code gets much used, since most of the rest of the world supports only a few specific curves; so even if the code is there, it was probably not thoroughly tested.