From 467dd34a9a260e4e6aab0c179b027907d29efedf Mon Sep 17 00:00:00 2001 From: Tobias Krause Date: Thu, 3 Feb 2011 16:22:52 +0100 Subject: tkr38: #i112307# Support for x509 v3 Subject Alternative Name extension added --- offapi/com/sun/star/security/CertAltNameEntry.idl | 59 ++++++++++++++ offapi/com/sun/star/security/ExtAltNameType.idl | 99 +++++++++++++++++++++++ offapi/com/sun/star/security/XSanExtension.idl | 57 +++++++++++++ offapi/com/sun/star/security/makefile.mk | 8 +- 4 files changed, 222 insertions(+), 1 deletion(-) create mode 100644 offapi/com/sun/star/security/CertAltNameEntry.idl create mode 100644 offapi/com/sun/star/security/ExtAltNameType.idl create mode 100644 offapi/com/sun/star/security/XSanExtension.idl diff --git a/offapi/com/sun/star/security/CertAltNameEntry.idl b/offapi/com/sun/star/security/CertAltNameEntry.idl new file mode 100644 index 000000000..40ad93d76 --- /dev/null +++ b/offapi/com/sun/star/security/CertAltNameEntry.idl @@ -0,0 +1,59 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + + +#ifndef __com_sun_star_security_CertAltNameEntry_idl__ +#define __com_sun_star_security_CertAltNameEntry_idl__ + +#include + +//============================================================================= + + module com { module sun { module star { module security { + +//============================================================================= +/** + * struct contains a single entry within a Subject Alternative Name Extension of a + * X509 certificate. + */ +struct CertAltNameEntry +{ + /** + * defines the type of the value . With this information you can determine how to interprete the Any value. + * @see com::sun::star::security::ExtAltNameType + */ + com::sun::star::security::ExtAltNameType Type; + + /** + * stores the value of entry. + */ + any Value; +}; + + +}; }; }; }; +#endif diff --git a/offapi/com/sun/star/security/ExtAltNameType.idl b/offapi/com/sun/star/security/ExtAltNameType.idl new file mode 100644 index 000000000..9154ad967 --- /dev/null +++ b/offapi/com/sun/star/security/ExtAltNameType.idl @@ -0,0 +1,99 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +/** -- idl definition -- **/ + +#ifndef __com_sun_star_security_ExtAltNameType_idl_ +#define __com_sun_star_security_ExtAltNameType_idl_ + +#include + +module com { module sun { module star { module security { + +/** + * Constant definiton of a single entry from Subject Alternative Name extension. + * + */ +enum ExtAltNameType +{ + /** + * Cutomize name/value pair + * The value of @see com::sun::star::security::CertAltNameEntry contains a NamedValue + */ + OTHER_NAME, + + /** + * The entry contains rfc822 name. + * The value of @see com::sun::star::security::CertAltNameEntry contains a OUString + */ + RFC822_NAME, + + /** + * The entry contains a dns name. + * The value of @see com::sun::star::security::CertAltNameEntry contains a OUString + */ + DNS_NAME, + + /** + * The entry contains a directory name. + * The value of @see com::sun::star::security::CertAltNameEntry contains a Sequence of sal_Int8 + */ + DIRECTORY_NAME, + + /** + * The entry contains an url. + * The value of @see com::sun::star::security::CertAltNameEntry contains a OUString + */ + URL, + + /** + * The entry contains a ip address. + * The value of @see com::sun::star::security::CertAltNameEntry contains a Sequence of sal_Int8 + */ + IP_ADDRESS, + + /** + * The entry contains a registered id. + * The value of @see com::sun::star::security::CertAltNameEntry contains a OUString + */ + REGISTERED_ID, + + /** + * Currently unsupported. + */ + EDI_PARTY_NAME, + + /** + * Currently unsupported. + */ + X400_ADDRESS +}; + +} ; } ; } ; } ; + +#endif + \ No newline at end of file diff --git a/offapi/com/sun/star/security/XSanExtension.idl b/offapi/com/sun/star/security/XSanExtension.idl new file mode 100644 index 000000000..54133d038 --- /dev/null +++ b/offapi/com/sun/star/security/XSanExtension.idl @@ -0,0 +1,57 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +//i20156 - new file for xmlsecurity module + +/** -- idl definition -- **/ + +#ifndef __com_sun_star_security_XSanExtension_idl_ +#define __com_sun_star_security_XSanExtension_idl_ + +#include +#include +#include + +module com { module sun { module star { module security { + +/** + * Interface of a X509 Subject Alternative Name Certificate Extension + * + *

This interface represents a x509 certificate extension.

+ */ +interface XSanExtension : com::sun::star::security::XCertificateExtension +{ + /** + * Contains the alternative names of a certificate + */ + [attribute, readonly] sequence< com::sun::star::security::CertAltNameEntry > AlternativeNames; +}; + +} ; } ; } ; } ; + +#endif + diff --git a/offapi/com/sun/star/security/makefile.mk b/offapi/com/sun/star/security/makefile.mk index 21667da10..2064e9fb4 100644 --- a/offapi/com/sun/star/security/makefile.mk +++ b/offapi/com/sun/star/security/makefile.mk @@ -59,7 +59,13 @@ IDLFILES=\ XSerialNumberAdapter.idl \ SerialNumberAdapter.idl \ CertificateContainer.idl \ - CertificateContainerStatus.idl + CertificateContainerStatus.idl \ + ExtAltNameType.idl \ + XSanExtension.idl \ + CertAltNameEntry.idl + + + # ------------------------------------------------------------------ -- cgit v1.2.3 From 6004f00c3db8b181ecdf95fcebd0d38d138c7aec Mon Sep 17 00:00:00 2001 From: Tobias Krause Date: Thu, 17 Feb 2011 09:58:41 +0100 Subject: tkr38: this idl file hangs in odk autodoc build. Addional comments fixed. --- offapi/com/sun/star/security/ExtAltNameType.idl | 33 ++++++++++++++++--------- 1 file changed, 22 insertions(+), 11 deletions(-) diff --git a/offapi/com/sun/star/security/ExtAltNameType.idl b/offapi/com/sun/star/security/ExtAltNameType.idl index 9154ad967..aec560a65 100644 --- a/offapi/com/sun/star/security/ExtAltNameType.idl +++ b/offapi/com/sun/star/security/ExtAltNameType.idl @@ -35,50 +35,60 @@ module com { module sun { module star { module security { /** - * Constant definiton of a single entry from Subject Alternative Name extension. - * + * Constant definiton of a certificate container status. */ enum ExtAltNameType { /** * Cutomize name/value pair - * The value of @see com::sun::star::security::CertAltNameEntry contains a NamedValue + * The value of CertAltNameEntry contains a NamedValue. + * + * @see com::sun::star::security::CertAltNameEntry */ OTHER_NAME, /** * The entry contains rfc822 name. - * The value of @see com::sun::star::security::CertAltNameEntry contains a OUString + * The value of CertAltNameEntry contains a OUString. + * + * @see com::sun::star::security::CertAltNameEntry */ RFC822_NAME, /** * The entry contains a dns name. - * The value of @see com::sun::star::security::CertAltNameEntry contains a OUString + * The value of CertAltNameEntry contains a OUString. + * + * @see com::sun::star::security::CertAltNameEntry */ DNS_NAME, /** - * The entry contains a directory name. - * The value of @see com::sun::star::security::CertAltNameEntry contains a Sequence of sal_Int8 + * Currently unsupported. */ DIRECTORY_NAME, /** * The entry contains an url. - * The value of @see com::sun::star::security::CertAltNameEntry contains a OUString + * The value of CertAltNameEntry contains a OUString. + * + * @see com::sun::star::security::CertAltNameEntry */ URL, /** * The entry contains a ip address. - * The value of @see com::sun::star::security::CertAltNameEntry contains a Sequence of sal_Int8 + * The value of CertAltNameEntry contains a Sequence of sal_Int8. + * + * @see com::sun::star::security::CertAltNameEntry */ IP_ADDRESS, /** * The entry contains a registered id. - * The value of @see com::sun::star::security::CertAltNameEntry contains a OUString + * The value of CertAltNameEntry contains a OUString. + * + * @see com::sun::star::security::CertAltNameEntry */ REGISTERED_ID, @@ -91,9 +101,10 @@ enum ExtAltNameType * Currently unsupported. */ X400_ADDRESS + }; } ; } ; } ; } ; #endif - \ No newline at end of file + -- cgit v1.2.3