public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/nordugrid-arc] f45: Update to version 7.2.0
@ 2026-09-07 8:38 Mattias Ellert
0 siblings, 0 replies; only message in thread
From: Mattias Ellert @ 2026-09-07 8:38 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : rpms/nordugrid-arc
Branch : f45
Commit : 3a38dd8f5b91c7c32e2793ae32ace7a2f9426038
Author : Mattias Ellert <mattias.ellert@physics.uu.se>
Date : 2026-09-07T10:26:55+02:00
Stats : +8/-793 in 6 file(s)
URL : https://src.fedoraproject.org/rpms/nordugrid-arc/c/3a38dd8f5b91c7c32e2793ae32ace7a2f9426038?branch=f45
Log:
Update to version 7.2.0
---
diff --git a/0001-Fix-compilation-with-Python-3.15.patch b/0001-Fix-compilation-with-Python-3.15.patch
deleted file mode 100644
index cc997b8..0000000
--- a/0001-Fix-compilation-with-Python-3.15.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From ccde2563178106d230b32585c35618cbe927551a Mon Sep 17 00:00:00 2001
-From: Mattias Ellert <mattias.ellert@physics.uu.se>
-Date: Wed, 12 Nov 2025 08:42:51 +0100
-Subject: [PATCH] Fix compilation with Python 3.15
-
-https://bugzilla.redhat.com/show_bug.cgi?id=2412512
-https://docs.python.org/dev/whatsnew/3.15.html#removed-c-apis
----
- python/arc_init.cpp | 14 +++++++++++++-
- 1 file changed, 13 insertions(+), 1 deletion(-)
-
-diff --git a/python/arc_init.cpp b/python/arc_init.cpp
-index 8459c84f2..02a631524 100644
---- a/python/arc_init.cpp
-+++ b/python/arc_init.cpp
-@@ -46,7 +46,19 @@ Note: it seems like Python is hiding site-packages part of path. Maybe it
- is hardcoded inside Python somewhere. But at least part till site-packages
- seems to be present.
- */
--#if PY_MAJOR_VERSION >= 3
-+#if PY_VERSION_HEX >= 0x030E0000
-+ std::string pythonpath;
-+ PyObject *paths = PyConfig_Get("module_search_paths");
-+ Py_ssize_t sz = PySequence_Size(paths);
-+ for (Py_ssize_t i = 0; i < sz; ++i) {
-+ PyObject *item = PySequence_GetItem(paths, i);
-+ std::string path = PyUnicode_AsUTF8(item);
-+ Py_DECREF(item);
-+ if (i > 0) pythonpath += ':';
-+ pythonpath += path;
-+ }
-+ Py_DECREF(paths);
-+#elif PY_MAJOR_VERSION >= 3
- std::wstring pythonwpath = Py_GetPath();
- std::string pythonpath(pythonwpath.begin(), pythonwpath.end());
- #else
---
-2.51.1
-
diff --git a/0001-Handle-Python-multi-phase-initialization-support-in-.patch b/0001-Handle-Python-multi-phase-initialization-support-in-.patch
deleted file mode 100644
index 3b99414..0000000
--- a/0001-Handle-Python-multi-phase-initialization-support-in-.patch
+++ /dev/null
@@ -1,95 +0,0 @@
-From 8738edf86196543f860a6878a573a36c3eaae249 Mon Sep 17 00:00:00 2001
-From: William S Fulton <wsf@fultondesigns.co.uk>
-Date: Sun, 19 Oct 2025 15:49:31 +0100
-Subject: [PATCH] Handle Python multi-phase initialization support in
- swig-4.4.0
-
-Fixes problem reported in https://github.com/swig/swig/issues/3266.
-
-Fix is implemented to support original Python single-phase module
-initialization that swig-4.3.1 and earlier generated as well as the
-new multi-phase module initialization that swig-4.0.0 generates.
-Arc subverts the normal module initialization by manually initializing
-other modules (common, loader message, communication, etc), during the
-initialization of arc. These other modules are also generated by SWIG
-for multi-phase initialization by the Python interpreter. The manual
-initialization by arc breaks and is worked around by implementing the
-'legacy initialization' approach documented in PEP-489
-https://peps.python.org/pep-0489/. This is not really standard as the
-legacy single-phase initialization is implemented even though SWIG
-has already started the multi-phase initialization. This is achieved
-by setting m_slots in PyModuleDef to NULL and manually calling the
-Py_mod_exec function in the slot to complete the second phase of the
-initialization.
-
-While this might work for now, a future proof approach would be
-for each of the modules to be initialized by the Python interpreter
-in the standard way by using proper sub-modules under a top level arc
-module/package.
----
- python/swigmodulesinit_wrap.cpp | 39 +++++++++++++++++++++++++++++++--
- 1 file changed, 37 insertions(+), 2 deletions(-)
-
-diff --git a/python/swigmodulesinit_wrap.cpp b/python/swigmodulesinit_wrap.cpp
-index ac110af2b..1e48d2d26 100644
---- a/python/swigmodulesinit_wrap.cpp
-+++ b/python/swigmodulesinit_wrap.cpp
-@@ -29,18 +29,53 @@ PyMODINIT_FUNC SWIG_init(data)(void);
- PyMODINIT_FUNC SWIG_init(delegation)(void);
- PyMODINIT_FUNC SWIG_init(security)(void);
-
-+/* Legacy init based on https://peps.python.org/pep-0489/ */
-+static PyObject *module_legacy_init(PyModuleDef *def) {
-+ PyModuleDef_Slot *slots = def->m_slots;
-+ def->m_slots = NULL;
-+ PyObject *mod = PyModule_Create(def);
-+ while (mod && slots->slot) {
-+ if (slots->slot == Py_mod_exec) {
-+ int (*mod_exec)(PyObject *) = (int (*)(PyObject *))slots->value;
-+ if (mod_exec(mod) != 0) {
-+ Py_DECREF(mod);
-+ mod = NULL;
-+ }
-+ }
-+ ++slots;
-+ }
-+ return mod;
-+}
-+
- static PyMODVAL init_extension_module(PyObject* package, const char *modulename,
- PyMODVAL (*initfunction)(void)) {
- #if PY_MAJOR_VERSION >= 3
-- PyObject *module = initfunction();
-+ // swig-4.4.0 implements PEP-489 multi-phase initialization.
-+ // Handle both old single-phase and new multi-phase initialization.
-+ // Modules that use multi-phase initialization will return a PyModuleDef, so then we force a legacy single-phase initialization.
-+ PyObject *module_or_module_def = initfunction();
-+ if (!module_or_module_def) {
-+ fprintf(stderr, "Failed first phase initializing Python module '%s', through Python C API\n", modulename);
-+ PyMOD_RETURN(NULL);
-+ }
-+ PyObject *module = NULL;
-+ if (PyObject_TypeCheck(module_or_module_def, &PyModuleDef_Type)) {
-+ module = module_legacy_init((PyModuleDef *)module_or_module_def);
-+ if (!module) {
-+ fprintf(stderr, "Failed second phase initializing Python module '%s', through Python C API\n", modulename);
-+ PyMOD_RETURN(NULL);
-+ }
-+ } else {
-+ module = module_or_module_def;
-+ }
- #else
- initfunction();
- PyObject *module = PyImport_AddModule((char *)modulename);
--#endif
- if(!module) {
- fprintf(stderr, "Failed initialising Python module '%s', through Python C API\n", modulename);
- PyMOD_RETURN(NULL);
- }
-+#endif
- if(PyModule_AddObject(package, (char *)modulename, module)) {
- fprintf(stderr, "Failied adding Python module '%s' to package 'arc', through Python C API\n", modulename);
- PyMOD_RETURN(NULL);
---
-2.51.0
-
diff --git a/0001-Support-OpenSSL-4.patch b/0001-Support-OpenSSL-4.patch
deleted file mode 100644
index 51289f7..0000000
--- a/0001-Support-OpenSSL-4.patch
+++ /dev/null
@@ -1,547 +0,0 @@
-From 21b7145d3f1a9408cc6fc8f4f25c3d006478a279 Mon Sep 17 00:00:00 2001
-From: Mattias Ellert <mattias.ellert@physics.uu.se>
-Date: Thu, 18 Jun 2026 18:56:29 +0200
-Subject: [PATCH] Support OpenSSL 4
-
----
- src/clients/compute/arctest.cpp | 4 ++
- src/hed/libs/credential/CertUtil.cpp | 28 +++++---
- src/hed/libs/credential/Credential.cpp | 66 ++++++++++---------
- src/hed/libs/credential/Proxycertinfo.cpp | 6 +-
- src/hed/libs/credential/VOMSUtil.cpp | 40 ++++++-----
- .../libs/delegation/DelegationInterface.cpp | 15 +++--
- src/hed/mcc/tls/DelegationCollector.cpp | 4 +-
- src/hed/mcc/tls/PayloadTLSMCC.cpp | 6 +-
- 8 files changed, 96 insertions(+), 73 deletions(-)
-
-diff --git a/src/clients/compute/arctest.cpp b/src/clients/compute/arctest.cpp
-index 184b7e518..024a0338a 100644
---- a/src/clients/compute/arctest.cpp
-+++ b/src/clients/compute/arctest.cpp
-@@ -337,7 +337,11 @@ int dumpjobdescription_arctest_legacy(const Arc::UserConfig& usercfg, Arc::Execu
- static bool get_hash_value(const Arc::Credential& c, std::string& hash_str) {
- X509* cert = c.GetCert();
- if(!cert) return false;
-+#if (OPENSSL_VERSION_NUMBER < 0x30000000L)
- X509_NAME* cert_name = X509_get_subject_name(cert);
-+#else
-+ const X509_NAME* cert_name = X509_get_subject_name(cert);
-+#endif
- if(!cert_name) return false;
-
- char hash[32];
-diff --git a/src/hed/libs/credential/CertUtil.cpp b/src/hed/libs/credential/CertUtil.cpp
-index 0776ee716..55217ec5c 100644
---- a/src/hed/libs/credential/CertUtil.cpp
-+++ b/src/hed/libs/credential/CertUtil.cpp
-@@ -306,8 +306,12 @@ static int verify_cert_additional(X509* cert, X509_STORE_CTX* store_ctx, std::st
-
- static bool collect_proxy_info(std::string& proxy_policy, X509* cert) {
- /**Check the proxy certificate infomation extension*/
-+#if (OPENSSL_VERSION_NUMBER < 0x40000000L)
- X509_EXTENSION* ext;
-- ASN1_OBJECT* extension_obj;
-+#else
-+ const X509_EXTENSION* ext;
-+#endif
-+ const ASN1_OBJECT* extension_obj;
- int i;
- for (i=0;i<X509_get_ext_count(cert);i++) {
- ext = (X509_EXTENSION *) X509_get_ext(cert,i);
-@@ -358,10 +362,10 @@ static bool collect_proxy_info(std::string& proxy_policy, X509* cert) {
- proxy_policy.clear();
- if((proxycertinfo->proxyPolicy) &&
- (proxycertinfo->proxyPolicy->policy) &&
-- (proxycertinfo->proxyPolicy->policy->data)) {
-+ ASN1_STRING_get0_data(proxycertinfo->proxyPolicy->policy)) {
- proxy_policy.append(
-- (char const*)(proxycertinfo->proxyPolicy->policy->data),
-- proxycertinfo->proxyPolicy->policy->length);
-+ (char const*) ASN1_STRING_get0_data(proxycertinfo->proxyPolicy->policy),
-+ ASN1_STRING_length(proxycertinfo->proxyPolicy->policy));
- }
- /* Use : as separator for policies parsed from different proxy certificate*/
- /* !!!! Taking int account previous proxy_policy.clear() !!!!
-@@ -387,8 +391,12 @@ bool check_cert_type(X509* cert, certType& type) {
- bool ret = false;
- type = CERT_TYPE_EEC;
-
-- ASN1_STRING* data;
-+ const ASN1_STRING* data;
-+#if (OPENSSL_VERSION_NUMBER < 0x40000000L)
- X509_EXTENSION* certinfo_ext;
-+#else
-+ const X509_EXTENSION* certinfo_ext;
-+#endif
- int policynid;
- PROXY_CERT_INFO_EXTENSION* certinfo_openssl = NULL;
-
-@@ -404,8 +412,8 @@ bool check_cert_type(X509* cert, certType& type) {
- }
-
- X509_NAME* issuer = NULL;
-- X509_NAME* subject = X509_get_subject_name(cert);
-- X509_NAME_ENTRY * name_entry = NULL;
-+ const X509_NAME* subject = X509_get_subject_name(cert);
-+ const X509_NAME_ENTRY * name_entry = NULL;
- if(!subject) goto err;
- name_entry = X509_NAME_get_entry(subject, X509_NAME_entry_count(subject)-1);
- if(!name_entry) goto err;
-@@ -413,8 +421,8 @@ bool check_cert_type(X509* cert, certType& type) {
- /* the name entry is of the type: common name */
- data = X509_NAME_ENTRY_get_data(name_entry);
- if(!data) goto err;
-- if (data->length == 5 && !memcmp(data->data,"proxy",5)) { type = CERT_TYPE_GSI_2_PROXY; }
-- else if(data->length == 13 && !memcmp(data->data,"limited proxy",13)) { type = CERT_TYPE_GSI_2_LIMITED_PROXY; }
-+ if (ASN1_STRING_length(data) == 5 && !memcmp(ASN1_STRING_get0_data(data),"proxy",5)) { type = CERT_TYPE_GSI_2_PROXY; }
-+ else if(ASN1_STRING_length(data) == 13 && !memcmp(ASN1_STRING_get0_data(data),"limited proxy",13)) { type = CERT_TYPE_GSI_2_LIMITED_PROXY; }
- else if((index = X509_get_ext_by_NID(cert, NID_proxyCertInfo, -1)) != -1) {
- certinfo_ext = X509_get_ext(cert,index);
- if(X509_EXTENSION_get_critical(certinfo_ext)) {
-@@ -453,7 +461,7 @@ bool check_cert_type(X509* cert, certType& type) {
- X509_NAME_ENTRY* new_name_entry = NULL;
- if(type != CERT_TYPE_EEC && type != CERT_TYPE_CA) {
- issuer = X509_NAME_dup(X509_get_issuer_name(cert));
-- new_name_entry = X509_NAME_ENTRY_create_by_NID(NULL, NID_commonName, V_ASN1_APP_CHOOSE, data->data, -1);
-+ new_name_entry = X509_NAME_ENTRY_create_by_NID(NULL, NID_commonName, V_ASN1_APP_CHOOSE, ASN1_STRING_get0_data(data), -1);
- if(!new_name_entry) goto err;
- X509_NAME_add_entry(issuer,new_name_entry,X509_NAME_entry_count(issuer),0);
- X509_NAME_ENTRY_free(new_name_entry);
-diff --git a/src/hed/libs/credential/Credential.cpp b/src/hed/libs/credential/Credential.cpp
-index 609f9a34d..439496eca 100644
---- a/src/hed/libs/credential/Credential.cpp
-+++ b/src/hed/libs/credential/Credential.cpp
-@@ -79,15 +79,15 @@ namespace Arc {
- ERR_print_errors_cb(&ssl_err_cb, &CredentialLogger);
- }
-
-- Time asn1_to_utctime(const ASN1_UTCTIME *s) {
-+ Time asn1_to_utctime(const ASN1_TIME *s) {
- if(s == NULL) return Time();
- std::string t_str;
-- if(s->type == V_ASN1_UTCTIME) {
-+ if(ASN1_STRING_type(s) == V_ASN1_UTCTIME) {
- t_str.append("20");
-- t_str.append((char*)(s->data));
-+ t_str.append((const char*) ASN1_STRING_get0_data(s));
- }
- else {//V_ASN1_GENERALIZEDTIME
-- t_str.append((char*)(s->data));
-+ t_str.append((const char*) ASN1_STRING_get0_data(s));
- }
- return Time(t_str);
- }
-@@ -124,7 +124,7 @@ namespace Arc {
- //Get the life time of the credential
- void Credential::GetLifetime(STACK_OF(X509) const * certchain, X509 const * cert, Time& start, Period &lifetime) {
- Time start_time(-1), end_time(-1);
-- ASN1_UTCTIME* atime = NULL;
-+ const ASN1_UTCTIME* atime = NULL;
-
- if(cert == NULL) {
- start = Time();
-@@ -135,20 +135,20 @@ namespace Arc {
- if(certchain) for (int n = 0; n < sk_X509_num(certchain); n++) {
- X509* tmp_cert = sk_X509_value(certchain, n);
-
-- atime = X509_getm_notAfter(tmp_cert);
-+ atime = X509_get0_notAfter(tmp_cert);
- Time e = asn1_to_utctime(atime);
- if (end_time == Time(-1) || e < end_time) { end_time = e; }
-
-- atime = X509_getm_notBefore(tmp_cert);
-+ atime = X509_get0_notBefore(tmp_cert);
- Time s = asn1_to_utctime(atime);
- if (start_time == Time(-1) || s > start_time) { start_time = s; }
- }
-
-- atime = X509_getm_notAfter(cert);
-+ atime = X509_get0_notAfter(cert);
- Time e = asn1_to_utctime(atime);
- if (end_time == Time(-1) || e < end_time) { end_time = e; }
-
-- atime = X509_getm_notBefore(cert);
-+ atime = X509_get0_notBefore(cert);
- Time s = asn1_to_utctime(atime);
- if (start_time == Time(-1) || s > start_time) { start_time = s; }
-
-@@ -249,7 +249,7 @@ namespace Arc {
- }
-
- std::string Credential::GetDN(void) const {
-- X509_NAME *subject = NULL;
-+ const X509_NAME *subject = NULL;
- if(!cert_) return "";
- subject = X509_get_subject_name(cert_);
- std::string str;
-@@ -269,19 +269,17 @@ namespace Arc {
- if(!cert_) return "";
- subject = X509_NAME_dup(X509_get_subject_name(cert_));
-
-- ASN1_STRING* entry;
-+ const ASN1_STRING* entry;
- std::string entry_str;
- for(;;) {
-- X509_NAME_ENTRY *ne = X509_NAME_get_entry(subject, X509_NAME_entry_count(subject)-1);
-+ const X509_NAME_ENTRY *ne = X509_NAME_get_entry(subject, X509_NAME_entry_count(subject)-1);
- if (!OBJ_cmp(X509_NAME_ENTRY_get_object(ne),OBJ_nid2obj(NID_commonName))) {
- entry = X509_NAME_ENTRY_get_data(ne);
-- entry_str.assign((const char*)(entry->data), (std::size_t)(entry->length));
-+ entry_str.assign((const char*) ASN1_STRING_get0_data(entry), (std::size_t) ASN1_STRING_length(entry));
- if(entry_str == "proxy" || entry_str == "limited proxy" ||
- entry_str.find_first_not_of("0123456789") == std::string::npos) {
- //Drop the name entry "proxy", "limited proxy", or the random digital(RFC)
-- ne = X509_NAME_delete_entry(subject, X509_NAME_entry_count(subject)-1);
-- X509_NAME_ENTRY_free(ne);
-- ne = NULL;
-+ X509_NAME_ENTRY_free(X509_NAME_delete_entry(subject, X509_NAME_entry_count(subject)-1));
- }
- else break;
- }
-@@ -305,7 +303,7 @@ namespace Arc {
- }
-
- std::string Credential::GetIssuerName(void) const {
-- X509_NAME *issuer = NULL;
-+ const X509_NAME *issuer = NULL;
- if(!cert_) return "";
- issuer = X509_get_issuer_name(cert_);
- std::string str;
-@@ -327,7 +325,7 @@ namespace Arc {
- // This works even if last cert on chain is CA
- // itself because CA is self-signed.
- X509 *cacert = sk_X509_value(cert_chain_, num-1);
-- X509_NAME *caname = X509_get_issuer_name(cacert);
-+ const X509_NAME *caname = X509_get_issuer_name(cacert);
- if(caname!=NULL) {
- char* buf = X509_NAME_oneline(caname,NULL,0);
- if(buf) {
-@@ -1158,16 +1156,12 @@ namespace Arc {
- return NULL;
- }
-
-- //ASN1_OCTET_STRING_set(ext_oct, data.c_str(), data.size());
-- ext_oct->data = (unsigned char*) malloc(data.size());
-- if(!(ext_oct->data)) {
-+ if (ASN1_OCTET_STRING_set(ext_oct, (const unsigned char *) data.c_str(), data.size()) == 0) {
- CredentialLogger.msg(ERROR, "Can not allocate memory for extension for proxy certificate");
- if(ext_oct) ASN1_OCTET_STRING_free(ext_oct);
- if(ext_obj) ASN1_OBJECT_free(ext_obj);
- return NULL;
- }
-- memcpy(ext_oct->data, data.c_str(), data.size());
-- ext_oct->length = data.size();
-
- X509_EXTENSION* ext = NULL;
- if (!(ext = X509_EXTENSION_create_by_OBJ(NULL, ext_obj, crit, ext_oct))) {
-@@ -1708,14 +1702,14 @@ namespace Arc {
- req_extensions = X509_REQ_get_extensions(req_);
- for(i=0;i<sk_X509_EXTENSION_num(req_extensions);i++) {
- X509_EXTENSION* ext = sk_X509_EXTENSION_value(req_extensions,i);
-- ASN1_OBJECT* extension_oid = X509_EXTENSION_get_object(ext);
-+ const ASN1_OBJECT* extension_oid = X509_EXTENSION_get_object(ext);
- int nid = OBJ_obj2nid(extension_oid);
- if(nid == NID_proxyCertInfo) {
- if(proxy_cert_info_) {
- PROXY_CERT_INFO_EXTENSION_free(proxy_cert_info_);
- proxy_cert_info_ = NULL;
- }
-- ASN1_OCTET_STRING* data = X509_EXTENSION_get_data(ext);
-+ const ASN1_OCTET_STRING* data = X509_EXTENSION_get_data(ext);
- if(!data) {
- CredentialLogger.msg(ERROR, "Missing data in DER encoded PROXY_CERT_INFO_EXTENSION extension");
- LogError(); goto err;
-@@ -1954,7 +1948,11 @@ err:
- int num;
- if ((num = X509_get_ext_count(cert_)) > 0) {
- for (int i = 0; i < num; i++) {
-+#if (OPENSSL_VERSION_NUMBER < 0x40000000L)
- X509_EXTENSION *ext;
-+#else
-+ const X509_EXTENSION *ext;
-+#endif
- const char *extname;
-
- ext = X509_get_ext(cert_, i);
-@@ -1970,18 +1968,18 @@ err:
- //Get x509 extension method structure
- if (!(method = (X509V3_EXT_METHOD *)(X509V3_EXT_get(ext)))) break;
-
-- ASN1_OCTET_STRING* extvalue = X509_EXTENSION_get_data(ext);
-- ext_value_data = extvalue->data;
-+ const ASN1_OCTET_STRING* extvalue = X509_EXTENSION_get_data(ext);
-+ ext_value_data = ASN1_STRING_get0_data(extvalue);
-
- //Decode ASN1 item in data
- if (method->it) {
- //New style ASN1
-- extstr = ASN1_item_d2i(NULL, &ext_value_data, extvalue->length,
-+ extstr = ASN1_item_d2i(NULL, &ext_value_data, ASN1_STRING_length(extvalue),
- ASN1_ITEM_ptr(method->it));
- }
- else {
- //Old style ASN1
-- extstr = method->d2i(NULL, &ext_value_data, extvalue->length);
-+ extstr = method->d2i(NULL, &ext_value_data, ASN1_STRING_length(extvalue));
- }
-
- val = method->i2v(method, extstr, NULL);
-@@ -2100,12 +2098,16 @@ err:
-
- position = X509_get_ext_by_NID(issuer, NID_ext_key_usage, -1);
- if(position > -1) {
-- X509_EXTENSION* ext = NULL;
-- if(!(ext = X509_get_ext(issuer, position))) {
-+#if (OPENSSL_VERSION_NUMBER < 0x30000000L)
-+ X509_EXTENSION* ext0;
-+#else
-+ const X509_EXTENSION* ext0;
-+#endif
-+ if(!(ext0 = X509_get_ext(issuer, position))) {
- CredentialLogger.msg(ERROR, "Can not get extended KeyUsage extension from issuer certificate");
- LogError(); goto err;
- }
-- ext = X509_EXTENSION_dup(ext);
-+ X509_EXTENSION* ext = X509_EXTENSION_dup(ext0);
- if(!ext) {
- CredentialLogger.msg(ERROR, "Can not copy extended KeyUsage extension");
- LogError(); goto err;
-diff --git a/src/hed/libs/credential/Proxycertinfo.cpp b/src/hed/libs/credential/Proxycertinfo.cpp
-index af24afd5e..6f0f214f7 100644
---- a/src/hed/libs/credential/Proxycertinfo.cpp
-+++ b/src/hed/libs/credential/Proxycertinfo.cpp
-@@ -54,12 +54,12 @@ int PROXY_POLICY_set_policy(PROXY_POLICY * proxypolicy, unsigned char * policy,
- unsigned char * PROXY_POLICY_get_policy(PROXY_POLICY * proxypolicy, int * length) {
- /* assure field policy is set */
- if(proxypolicy->policy) {
-- *length = proxypolicy->policy->length;
-+ *length = ASN1_STRING_length(proxypolicy->policy);
- /* assure ASN1_OCTET_STRING is full */
-- if (*length>0 && proxypolicy->policy->data) {
-+ if (*length > 0 && ASN1_STRING_get0_data(proxypolicy->policy)) {
- unsigned char * copy = (unsigned char*) malloc(*length);
- if(copy) {
-- memcpy(copy, proxypolicy->policy->data, *length);
-+ memcpy(copy, ASN1_STRING_get0_data(proxypolicy->policy), *length);
- return copy;
- }
- }
-diff --git a/src/hed/libs/credential/VOMSUtil.cpp b/src/hed/libs/credential/VOMSUtil.cpp
-index 2b4f1335f..8a4a58ea8 100644
---- a/src/hed/libs/credential/VOMSUtil.cpp
-+++ b/src/hed/libs/credential/VOMSUtil.cpp
-@@ -818,7 +818,7 @@ err:
- // const_cast hack due to missing set method
- const ASN1_BIT_STRING* bstr = X509_ACERT_get0_issuerUID(a);
- if(bstr)
-- ASN1_BIT_STRING_set(const_cast<ASN1_BIT_STRING*>(bstr), uid->data, uid->length);
-+ ASN1_BIT_STRING_set(const_cast<ASN1_BIT_STRING*>(bstr), const_cast<unsigned char*>(ASN1_STRING_get0_data(uid)), ASN1_STRING_length(uid));
- }
-
- if(alg1) {
-@@ -1455,7 +1455,7 @@ err:
- GENERAL_NAME *data = sk_GENERAL_NAME_value(OSSL_IETF_ATTR_SYNTAX_get0_policyAuthority(capattr), 0);
- if (data && data->type == GEN_URI) {
- std::string voname("/voname=");
-- voname.append((const char*)(data->d.ia5->data), data->d.ia5->length);
-+ voname.append((const char*) ASN1_STRING_get0_data(data->d.ia5), ASN1_STRING_length(data->d.ia5));
- std::string::size_type pos = voname.find("://");
- if(pos != std::string::npos) {
- voname.replace(pos,3,"/hostname=");
-@@ -1479,7 +1479,7 @@ err:
- return false;
- }
-
-- std::string fqan((const char*)(capname->data), capname->length);
-+ std::string fqan((const char*) ASN1_STRING_get0_data(capname), ASN1_STRING_length(capname));
-
- // if the attribute is like: /knowarc.eu/Role=NULL/Capability=NULL
- // or /knowarc.eu/Role=tester/Capability=NULL
-@@ -1533,7 +1533,7 @@ err:
- STACK_OF(AC_ATTRIBUTE) *atts = holder->attributes;
-
- gn = sk_GENERAL_NAME_value(holder->grantor, 0);
-- grantor.assign((const char*)(gn->d.ia5->data), gn->d.ia5->length);
-+ grantor.assign((const char*) ASN1_STRING_get0_data(gn->d.ia5), ASN1_STRING_length(gn->d.ia5));
- if(grantor.empty()) {
- CredentialLogger.msg(ERROR,"VOMS: the grantor attribute is empty");
- status |= VOMSACInfo::InternalParsingFailed;
-@@ -1551,18 +1551,18 @@ err:
- std::string attribute;
- AC_ATTRIBUTE *at = sk_AC_ATTRIBUTE_value(atts, j);
-
-- name.assign((const char*)(at->name->data), at->name->length);
-+ name.assign((const char*) ASN1_STRING_get0_data(at->name), ASN1_STRING_length(at->name));
- if(name.empty()) {
- CredentialLogger.msg(ERROR,"VOMS: the attribute name is empty");
- status |= VOMSACInfo::InternalParsingFailed;
- return false;
- }
-- value.assign((const char*)(at->value->data), at->value->length);
-+ value.assign((const char*) ASN1_STRING_get0_data(at->value), ASN1_STRING_length(at->value));
- if(value.empty()) {
- CredentialLogger.msg(WARNING,"VOMS: the attribute value for %s is empty", name.c_str());
- //return false;
- }
-- qualifier.assign((const char*)(at->qualifier->data), at->qualifier->length);
-+ qualifier.assign((const char*) ASN1_STRING_get0_data(at->qualifier), ASN1_STRING_length(at->qualifier));
- if(qualifier.empty()) {
- CredentialLogger.msg(ERROR,"VOMS: the attribute qualifier is empty");
- status |= VOMSACInfo::InternalParsingFailed;
-@@ -1794,14 +1794,14 @@ err:
- if (iss) {
- if (key->keyid) {
- unsigned char hashed[20];
-- ASN1_BIT_STRING* pkeystr = X509_get0_pubkey_bitstr(iss);
-- if (!SHA1(pkeystr->data,
-- pkeystr->length,
-+ const ASN1_BIT_STRING* pkeystr = X509_get0_pubkey_bitstr(iss);
-+ if (!SHA1(ASN1_STRING_get0_data(pkeystr),
-+ ASN1_STRING_length(pkeystr),
- hashed))
- keyerr = true;
-
-- if ((memcmp(key->keyid->data, hashed, 20) != 0) &&
-- (key->keyid->length == 20))
-+ if ((memcmp(ASN1_STRING_get0_data(key->keyid), hashed, 20) != 0) &&
-+ (ASN1_STRING_length(key->keyid) == 20))
- keyerr = true;
- }
- else {
-@@ -1838,8 +1838,8 @@ err:
- }
-
- static time_t ASN1_GENERALIZEDTIME_get(const ASN1_GENERALIZEDTIME* const s) {
-- if ((s == NULL) || (s->data == NULL) || (s->length == 0)) return Arc::Time::UNDEFINED;
-- std::string str((char const *)(s->data), s->length);
-+ if ((s == NULL) || (ASN1_STRING_get0_data(s) == NULL) || (ASN1_STRING_length(s) == 0)) return Arc::Time::UNDEFINED;
-+ std::string str((char const *) ASN1_STRING_get0_data(s), ASN1_STRING_length(s));
- Arc::Time t(str);
- return t.GetTime();
- }
-@@ -2050,7 +2050,7 @@ err:
- ctime += 300;
- dtime = ctime-600;
-
-- if ((start->type != V_ASN1_GENERALIZEDTIME) || (end->type != V_ASN1_GENERALIZEDTIME)) {
-+ if ((ASN1_STRING_type(start) != V_ASN1_GENERALIZEDTIME) || (ASN1_STRING_type(end) != V_ASN1_GENERALIZEDTIME)) {
- CredentialLogger.msg(ERROR,"VOMS: unsupported time format in AC - expecting GENERALIZED TIME");
- status |= VOMSACInfo::ACParsingFailed;
- return false; // ?
-@@ -2181,7 +2181,7 @@ err:
- }
- }
-
-- if (X509_ACERT_get0_serialNumber(ac)->length > 20) {
-+ if (ASN1_STRING_length(X509_ACERT_get0_serialNumber(ac)) > 20) {
- CredentialLogger.msg(ERROR,"VOMS: the serial number of AC INFO is too long - expecting no more than 20 octets");
- status |= VOMSACInfo::InternalParsingFailed;
- return false;
-@@ -2261,7 +2261,7 @@ err:
- return false;
- }
-
-- std::string voname((const char *)name->d.ia5->data, 0, name->d.ia5->length);
-+ std::string voname((const char *) ASN1_STRING_get0_data(name->d.ia5), 0, ASN1_STRING_length(name->d.ia5));
- std::string::size_type cpos = voname.find("://");
- std::string hostname;
- if (cpos != std::string::npos) {
-@@ -2314,7 +2314,11 @@ err:
- int nid = 0;
- int position = 0;
- bool critical = false;
-+#if (OPENSSL_VERSION_NUMBER < 0x40000000L)
- X509_EXTENSION * ext;
-+#else
-+ const X509_EXTENSION * ext;
-+#endif
- AC_SEQ* aclist = NULL;
- nid = OBJ_txt2nid(acseqOID);
- position = X509_get_ext_by_NID(holder, nid, -1);
-@@ -2675,7 +2679,7 @@ err:
- ext = X509V3_EXT_conf_nid(NULL, NULL, OBJ_txt2nid(acseqOID), (char*)(ac_seq.c_str()));
- if(ext!=NULL) {
- asn1.clear();
-- asn1.assign((const char*)(X509_EXTENSION_get_data(ext)->data), X509_EXTENSION_get_data(ext)->length);
-+ asn1.assign((const char*) ASN1_STRING_get0_data(X509_EXTENSION_get_data(ext)), ASN1_STRING_length(X509_EXTENSION_get_data(ext)));
- ret = true;
- X509_EXTENSION_free(ext);
- }
-diff --git a/src/hed/libs/delegation/DelegationInterface.cpp b/src/hed/libs/delegation/DelegationInterface.cpp
-index ad61e40d0..a9df879db 100644
---- a/src/hed/libs/delegation/DelegationInterface.cpp
-+++ b/src/hed/libs/delegation/DelegationInterface.cpp
-@@ -214,8 +214,8 @@ err:
-
- static Time asn1_to_time(const ASN1_UTCTIME *s) {
- if(s != NULL) {
-- if(s->type == V_ASN1_UTCTIME) return Time(std::string("20")+((char*)(s->data)));
-- if(s->type == V_ASN1_GENERALIZEDTIME) return Time(std::string((char*)(s->data)));
-+ if(ASN1_STRING_type(s) == V_ASN1_UTCTIME) return Time(std::string("20")+((const char*)(ASN1_STRING_get0_data(s))));
-+ if(ASN1_STRING_type(s) == V_ASN1_GENERALIZEDTIME) return Time(std::string((const char*)(ASN1_STRING_get0_data(s))));
- }
- return Time(Time::UNDEFINED);
- }
-@@ -648,6 +648,11 @@ std::string DelegationProvider::Delegate(const std::string& request,const Delega
- PROXY_POLICY proxy_policy;
- const EVP_MD *digest = EVP_sha256();
- X509_NAME *subject = NULL;
-+#if (OPENSSL_VERSION_NUMBER < 0x30000000L)
-+ X509_NAME *subject_c = NULL;
-+#else
-+ const X509_NAME *subject_c = NULL;
-+#endif
- const char* need_ext = "critical,digitalSignature,keyEncipherment";
- std::string proxy_cn;
- std::string res;
-@@ -814,9 +819,9 @@ std::string DelegationProvider::Delegate(const std::string& request,const Delega
- } PROXY_POLICY;
- */
-
-- subject=X509_get_subject_name((X509*)cert_);
-- if(!subject) goto err;
-- subject=X509_NAME_dup(subject);
-+ subject_c=X509_get_subject_name((X509*)cert_);
-+ if(!subject_c) goto err;
-+ subject=X509_NAME_dup(subject_c);
- if(!subject) goto err;
- if(!X509_set_issuer_name(cert,subject)) goto err;
- if(!X509_NAME_add_entry_by_NID(subject,NID_commonName,MBSTRING_ASC,(unsigned char*)(proxy_cn.c_str()),proxy_cn.length(),-1,0)) goto err;
-diff --git a/src/hed/mcc/tls/DelegationCollector.cpp b/src/hed/mcc/tls/DelegationCollector.cpp
-index 5d9c04dfc..2dcbb66b4 100644
---- a/src/hed/mcc/tls/DelegationCollector.cpp
-+++ b/src/hed/mcc/tls/DelegationCollector.cpp
-@@ -45,8 +45,8 @@ static bool get_proxy_policy(X509* cert,DelegationMultiSecAttr* sattr) {
- }; break;
- case NID_id_ppl_anyLanguage: { // Here we store ARC policy
- // Either this is ARC policy is determined by examining content
-- const char* policy_str = (const char *)(pci->proxyPolicy->policy->data);
-- int policy_length = pci->proxyPolicy->policy->length;
-+ const char* policy_str = (const char *) ASN1_STRING_get0_data(pci->proxyPolicy->policy);
-+ int policy_length = ASN1_STRING_length(pci->proxyPolicy->policy);
- if((policy_str == NULL) || (policy_length <= 0)) {
- logger.msg(DEBUG,"Proxy with empty policy - fail on unrecognized policy");
- break;
-diff --git a/src/hed/mcc/tls/PayloadTLSMCC.cpp b/src/hed/mcc/tls/PayloadTLSMCC.cpp
-index 81ad9d71f..358fac844 100644
---- a/src/hed/mcc/tls/PayloadTLSMCC.cpp
-+++ b/src/hed/mcc/tls/PayloadTLSMCC.cpp
-@@ -20,12 +20,12 @@ int PayloadTLSMCC::ex_data_index_ = -1;
- Time asn1_to_utctime(const ASN1_UTCTIME *s) {
- std::string t_str;
- if(!s) return Time();
-- if(s->type == V_ASN1_UTCTIME) {
-+ if(ASN1_STRING_type(s) == V_ASN1_UTCTIME) {
- t_str.append("20");
-- t_str.append((char*)(s->data));
-+ t_str.append((const char*) ASN1_STRING_get0_data(s));
- }
- else {//V_ASN1_GENERALIZEDTIME
-- t_str.append((char*)(s->data));
-+ t_str.append((const char*) ASN1_STRING_get0_data(s));
- }
- return Time(t_str);
- }
---
-2.54.0
-
diff --git a/0001-Use-Python-3-API-in-SWIG-wrwppers.patch b/0001-Use-Python-3-API-in-SWIG-wrwppers.patch
deleted file mode 100644
index 411154a..0000000
--- a/0001-Use-Python-3-API-in-SWIG-wrwppers.patch
+++ /dev/null
@@ -1,93 +0,0 @@
-From 2dbee3b5a003ff9c8fb5f9ecbac9640eae6ea9d5 Mon Sep 17 00:00:00 2001
-From: Mattias Ellert <mattias.ellert@physics.uu.se>
-Date: Tue, 18 Aug 2026 10:26:08 +0200
-Subject: [PATCH] Use Python 3 API in SWIG wrwppers
-
-Don't rely on Python 2 compatibility macros in the SWIG headers.
-They were removed in SWIG 4.5.0.
----
- swig/Arc.i | 10 ++++++++++
- swig/data.i | 16 ++++++++++++----
- 2 files changed, 22 insertions(+), 4 deletions(-)
-
-diff --git a/swig/Arc.i b/swig/Arc.i
-index 28ce22c58..b5667df22 100644
---- a/swig/Arc.i
-+++ b/swig/Arc.i
-@@ -90,7 +90,9 @@ class StaticPropertyWrapper(object):
- %typemap(in) time_t
- {
- if (PyLong_Check($input)) $1 = (time_t) PyLong_AsLong($input);
-+%#if PY_VERSION_HEX < 0x03000000
- else if (PyInt_Check($input)) $1 = (time_t) PyInt_AsLong($input);
-+%#endif
- else if (PyFloat_Check($input)) $1 = (time_t) PyFloat_AsDouble($input);
- else {
- PyErr_SetString(PyExc_TypeError,"Expected a large type");
-@@ -107,7 +109,11 @@ class StaticPropertyWrapper(object):
-
- %typemap(in) uint32_t
- {
-+%#if PY_VERSION_HEX < 0x03000000
- if (PyInt_Check($input)) $1 = (uint32_t) PyInt_AsLong($input);
-+%#else
-+ if (PyLong_Check($input)) $1 = (uint32_t) PyLong_AsLong($input);
-+%#endif
- else if (PyFloat_Check($input)) $1 = (uint32_t) PyFloat_AsDouble($input);
- else {
- PyErr_SetString(PyExc_TypeError,"Unable to convert type to 32bit number (int/float)");
-@@ -118,7 +124,11 @@ class StaticPropertyWrapper(object):
-
- %typemap(out) uint32_t
- {
-+%#if PY_VERSION_HEX < 0x03000000
- $result = PyInt_FromLong((int)$1);
-+%#else
-+ $result = PyLong_FromLong((int)$1);
-+%#endif
- }
- #endif
-
-diff --git a/swig/data.i b/swig/data.i
-index 8a6dba612..66a8efee6 100644
---- a/swig/data.i
-+++ b/swig/data.i
-@@ -121,23 +121,31 @@ typedef struct {
-
- %typemap(out) Arc::DataBufferForWriteResult {
- $result = PyTuple_New(5);
-+%#if PY_VERSION_HEX >= 0x03000000
-+ PyTuple_SetItem($result,0,PyLong_FromLong($1.result));
-+ PyTuple_SetItem($result,1,PyLong_FromLong($1.handle));
-+ PyTuple_SetItem($result,2,PyLong_FromLong($1.size));
-+ PyTuple_SetItem($result,3,PyLong_FromLong($1.offset));
-+ PyTuple_SetItem($result,4,$1.buffer?PyUnicode_FromStringAndSize($1.buffer,$1.size):Py_None);
-+%#else
- PyTuple_SetItem($result,0,PyInt_FromLong($1.result));
- PyTuple_SetItem($result,1,PyInt_FromLong($1.handle));
- PyTuple_SetItem($result,2,PyInt_FromLong($1.size));
- PyTuple_SetItem($result,3,PyInt_FromLong($1.offset));
--%#if PY_VERSION_HEX>=0x03000000
-- PyTuple_SetItem($result,4,$1.buffer?PyUnicode_FromStringAndSize($1.buffer,$1.size):Py_None);
--%#else
- PyTuple_SetItem($result,4,$1.buffer?PyString_FromStringAndSize($1.buffer,$1.size):Py_None);
- %#endif
- }
-
- %typemap(out) Arc::DataBufferForReadResult {
-+%#if PY_VERSION_HEX >= 0x03000000
-+ $result = PyTuple_Pack(3, PyLong_FromLong($1.result), PyLong_FromLong($1.handle), PyLong_FromLong($1.size));
-+%#else
- $result = PyTuple_Pack(3, PyInt_FromLong($1.result), PyInt_FromLong($1.handle), PyInt_FromLong($1.size));
-+%#endif
- }
-
- %typemap(in) (char* DataBufferIsReadBuf, unsigned int DataBufferIsReadSize) {
--%#if PY_VERSION_HEX>=0x03000000
-+%#if PY_VERSION_HEX >= 0x03000000
- $input = PyUnicode_AsUTF8String($input);
- $1 = PyBytes_AsString($input);
- $2 = ($1)?PyBytes_Size($input):0;
---
-2.55.0
-
diff --git a/nordugrid-arc.spec b/nordugrid-arc.spec
index 439fdc7..8500634 100644
--- a/nordugrid-arc.spec
+++ b/nordugrid-arc.spec
@@ -22,24 +22,14 @@
%global _bashcompdir %(pkg-config --variable=completionsdir bash-completion 2>/dev/null || echo %{_sysconfdir}/bash_completion.d)
Name: nordugrid-arc
-Version: 7.1.2
-Release: 8%{?dist}
+Version: 7.2.0
+Release: 1%{?dist}
Summary: Advanced Resource Connector Middleware
# Apache-2.0: most files
# MIT: src/external/cJSON/cJSON.c src/external/cJSON/cJSON.h
License: Apache-2.0 AND MIT
URL: https://www.nordugrid.org/
Source: https://download.nordugrid.org/packages/%{name}/releases/%{version}/src/%{name}-%{version}.tar.gz
-# Support SWIG 4.4.0 (patch from William S Fulton)
-# https://github.com/nordugrid/arc/pull/15
-# https://source.coderefinery.org/nordugrid/arc/-/merge_requests/1964
-Patch0: 0001-Handle-Python-multi-phase-initialization-support-in-.patch
-# https://source.coderefinery.org/nordugrid/arc/-/merge_requests/1971
-Patch1: 0001-Fix-compilation-with-Python-3.15.patch
-# https://source.coderefinery.org/nordugrid/arc/-/merge_requests/1997
-Patch2: 0001-Support-OpenSSL-4.patch
-# https://source.coderefinery.org/nordugrid/arc/-/merge_requests/2012
-Patch3: 0001-Use-Python-3-API-in-SWIG-wrwppers.patch
# Packages dropped without replacements
Obsoletes: %{name}-arcproxyalt < 6.0.0
@@ -484,7 +474,7 @@ Header files and libraries needed to develop applications using ARC.
%package -n python3-%{name}
Summary: ARC Python 3 wrapper
-%{?python_provide:%python_provide python3-%{name}}
+%py_provides python3-%{name}
Requires: %{name} = %{version}-%{release}
%description -n python3-%{name}
@@ -536,7 +526,7 @@ management features on the worker nodes (WN).
%package -n python3-arcrest
Summary: ARC REST client
-%{?python_provide:%python_provide python3-arcrest}
+%py_provides python3-arcrest
BuildArch: noarch
%description -n python3-arcrest
@@ -561,10 +551,6 @@ publishes metrics about jobs and datastaging on the ARC-CE.
%prep
%setup -q
-%patch -P0 -p1
-%patch -P1 -p1
-%patch -P2 -p1
-%patch -P3 -p1
%build
autoreconf -v -f -i
@@ -1143,6 +1129,9 @@ semanage fcontext -a -t slapd_var_run_t "/var/run/arc/bdii/db(/.*)?" 2>/dev/null
%{_sbindir}/arc-exporter
%changelog
+* Tue Sep 01 2026 Mattias Ellert <mattias.ellert@physics.uu.se> - 7.2.0-1
+- Update to version 7.2.0
+
* Tue Aug 18 2026 Mattias Ellert <mattias.ellert@physics.uu.se> - 7.1.2-8
- Use upstream's patch for SWIG 4.5.0 support
diff --git a/sources b/sources
index 29497e8..366c4a6 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-SHA512 (nordugrid-arc-7.1.2.tar.gz) = 5cfa3778197f87fdc4d999fba56153257aa099168137387ded5520d580bdbf046f48d94dccb226d4356f36979d5a128d2828c0fa47a96c64305b9c92340bef83
+SHA512 (nordugrid-arc-7.2.0.tar.gz) = 8b9f0d8f6337ab61a9fc83bf2fb3168a6c6430abb12d603a3b39a8da78a5405b24ba6ba6089a473f022fb33401a67a37b52515f232e7c75d875150c8fba105b1
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-09-07 8:38 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-07 8:38 [rpms/nordugrid-arc] f45: Update to version 7.2.0 Mattias Ellert
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox