Browse Source

2020-08-19 Fred Gleason <fredg@paravelsystems.com>

* Added a 'STATIONS.SSH_IDENTITY_FILE' field to the database.
	* Added a 'RECORDINGS.URL_USE_ID_FILE' field to the database.
	* Added a 'FEEDS.PURGE_USE_ID_FILE' field to the database.
	* Incremented the database version to 333.
	* Added 'RDStation::sshIdentityFile()' and
	'RDStation::setSshIdentityFile()' methods.
	* Added 'RDRecording::urlUseIdFile()' and
	'RDRecording::setUrlUseIdFile()' methods.
	* Added 'RDFeed::purgeUseIdFile()' and 'RDFeed::setPurgeUseIdFile()'
	methods.
	* Added a 'SSH Ident. File' control to the 'Host' dialog in
	rdadmin(1).
	* Added an 'Authenticate with local identity file' checkbox to
	the 'Feed' dialog in rdadmin(1).

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
db-merging
Fred Gleason 3 years ago
parent
commit
ecd2a2d427
  1. 15
      ChangeLog
  2. 1
      docs/tables/feeds.txt
  3. 1
      docs/tables/recordings.txt
  4. 1
      docs/tables/stations.txt
  5. 2
      lib/dbversion.h
  6. 20
      lib/rddelete.cpp
  7. 2
      lib/rddelete.h
  8. 20
      lib/rddownload.cpp
  9. 2
      lib/rddownload.h
  10. 44
      lib/rdfeed.cpp
  11. 2
      lib/rdfeed.h
  12. 2
      lib/rdpodcast.cpp
  13. 14
      lib/rdrecording.cpp
  14. 6
      lib/rdrecording.h
  15. 13
      lib/rdstation.cpp
  16. 2
      lib/rdstation.h
  17. 19
      lib/rdupload.cpp
  18. 2
      lib/rdupload.h
  19. 150
      rdadmin/edit_feed.cpp
  20. 3
      rdadmin/edit_feed.h
  21. 140
      rdadmin/edit_station.cpp
  22. 2
      rdadmin/edit_station.h
  23. 18
      rdadmin/list_images.cpp
  24. 4
      rdadmin/list_images.h
  25. 8
      rdadmin/rdadmin_cs.ts
  26. 8
      rdadmin/rdadmin_de.ts
  27. 8
      rdadmin/rdadmin_es.ts
  28. 8
      rdadmin/rdadmin_fr.ts
  29. 8
      rdadmin/rdadmin_nb.ts
  30. 8
      rdadmin/rdadmin_nn.ts
  31. 8
      rdadmin/rdadmin_pt_BR.ts
  32. 10
      rdcatchd/batch.cpp
  33. 10
      rdrepld/citadelxds.cpp
  34. 12
      tests/delete_test.cpp
  35. 4
      tests/delete_test.h
  36. 20
      tests/download_test.cpp
  37. 6
      tests/download_test.h
  38. 12
      tests/upload_test.cpp
  39. 4
      tests/upload_test.h
  40. 11
      utils/rddbmgr/revertschema.cpp
  41. 2
      utils/rddbmgr/schemamap.cpp
  42. 22
      utils/rddbmgr/updateschema.cpp

15
ChangeLog

@ -20244,3 +20244,18 @@
'Podcast Feed Item List' dialog in rdcastmanager(1).
2020-08-13 Fred Gleason <fredg@paravelsystems.com>
* Added an 'RDCastManager' chapter to the Operations Guide.
2020-08-19 Fred Gleason <fredg@paravelsystems.com>
* Added a 'STATIONS.SSH_IDENTITY_FILE' field to the database.
* Added a 'RECORDINGS.URL_USE_ID_FILE' field to the database.
* Added a 'FEEDS.PURGE_USE_ID_FILE' field to the database.
* Incremented the database version to 333.
* Added 'RDStation::sshIdentityFile()' and
'RDStation::setSshIdentityFile()' methods.
* Added 'RDRecording::urlUseIdFile()' and
'RDRecording::setUrlUseIdFile()' methods.
* Added 'RDFeed::purgeUseIdFile()' and 'RDFeed::setPurgeUseIdFile()'
methods.
* Added a 'SSH Ident. File' control to the 'Host' dialog in
rdadmin(1).
* Added an 'Authenticate with local identity file' checkbox to
the 'Feed' dialog in rdadmin(1).

1
docs/tables/feeds.txt

@ -27,6 +27,7 @@ BASE_PREAMBLE varchar(191)
PURGE_URL varchar(191)
PURGE_USERNAME varchar(64)
PURGE_PASSWORD varchar(64)
PURGE_USE_ID_FILE enum('N','Y')
RSS_SCHEMA int(10) unsigned 0=Custom, 1=RSS-2.0.2
HEADER_XML text
CHANNEL_XML text

1
docs/tables/recordings.txt

@ -60,5 +60,6 @@ ONE_SHOT enum ('N','Y')
URL varchar(255)
URL_USERNAME varchar(64)
URL_PASSWORD varchar(64)
URL_USE_ID_FILE enum('N','Y')
ENABLE_METADATA enum('N','Y')
FEED_ID int From FEEDS.ID

1
docs/tables/stations.txt

@ -20,6 +20,7 @@ STARTUP_CART int(10) unsigned
EDITOR_PATH varchar(191) Audio editor --e.g. Audacity
REPORT_EDITOR_PATH varchar(191) Text Editor --e.g. GEdit
BROWSER_PATH varchar(191) Web Browser --e.g. Firefox
SSH_IDENTITY_FILE text
FILTER_MODE int(11) 0=Synchronous, 1=Asynchronous
START_JACK enum('Y','N')
JACK_SERVER_NAME varchar(64)

2
lib/dbversion.h

@ -24,7 +24,7 @@
/*
* Current Database Version
*/
#define RD_VERSION_DATABASE 332
#define RD_VERSION_DATABASE 333
#endif // DBVERSION_H

20
lib/rddelete.cpp

@ -94,6 +94,8 @@ void RDDelete::setTargetUrl(const QString &url)
RDDelete::ErrorCode RDDelete::runDelete(const QString &username,
const QString &password,
const QString &id_filename,
bool use_id_filename,
bool log_debug)
{
CURL *curl=NULL;
@ -103,6 +105,7 @@ RDDelete::ErrorCode RDDelete::runDelete(const QString &username,
QString currentdir;
QString filename;
QString xml="";
char userpwd[256];
if(!urlIsSupported(conv_target_url)) {
return RDDelete::ErrorUnsupportedUrlScheme;
@ -118,9 +121,22 @@ RDDelete::ErrorCode RDDelete::runDelete(const QString &username,
return RDDelete::ErrorInternal;
}
//
// Authentication
//
if((conv_target_url.scheme().toLower()=="sftp")&&
(!id_filename.isEmpty())&&use_id_filename) {
curl_easy_setopt(curl,CURLOPT_USERNAME,username.toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_SSH_PRIVATE_KEYFILE,
id_filename.toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_KEYPASSWD,password.toUtf8().constData());
}
else {
strncpy(userpwd,(username+":"+password).utf8(),256);
curl_easy_setopt(curl,CURLOPT_USERPWD,userpwd);
}
curl_easy_setopt(curl,CURLOPT_URL,conv_target_url.toEncoded().constData());
curl_easy_setopt(curl,CURLOPT_USERNAME,username.toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_PASSWORD,password.toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_HTTPAUTH,CURLAUTH_ANY);
curl_easy_setopt(curl,CURLOPT_WRITEFUNCTION,DeleteWriteCallback);
curl_easy_setopt(curl,CURLOPT_WRITEDATA,&xml);

2
lib/rddelete.h

@ -43,6 +43,8 @@ class RDDelete : public RDTransfer
void setTargetUrl(const QString &url);
RDDelete::ErrorCode runDelete(const QString &username,
const QString &password,
const QString &id_filename,
bool use_id_filename,
bool log_debug);
static QString errorText(RDDelete::ErrorCode err);

20
lib/rddownload.cpp

@ -112,6 +112,8 @@ int RDDownload::totalSteps() const
RDDownload::ErrorCode RDDownload::runDownload(const QString &username,
const QString &password,
const QString &id_filename,
bool use_id_filename,
bool log_debug)
{
CURL *curl=NULL;
@ -120,6 +122,7 @@ RDDownload::ErrorCode RDDownload::runDownload(const QString &username,
long response_code=0;
RDDownload::ErrorCode ret=RDDownload::ErrorOk;
RDSystemUser *user=NULL;
char userpwd[256];
if(!urlIsSupported(conv_src_url)) {
return RDDownload::ErrorUnsupportedProtocol;
@ -155,10 +158,23 @@ RDDownload::ErrorCode RDDownload::runDownload(const QString &username,
//
url.replace("#","%23");
//
// Authentication
//
if((conv_src_url.scheme().toLower()=="sftp")&&
(!id_filename.isEmpty())&&use_id_filename) {
curl_easy_setopt(curl,CURLOPT_USERNAME,username.toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_SSH_PRIVATE_KEYFILE,
id_filename.toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_KEYPASSWD,password.toUtf8().constData());
}
else {
strncpy(userpwd,(username+":"+password).utf8(),256);
curl_easy_setopt(curl,CURLOPT_USERPWD,userpwd);
}
curl_easy_setopt(curl,CURLOPT_URL,url.constData());
curl_easy_setopt(curl,CURLOPT_WRITEDATA,f);
curl_easy_setopt(curl,CURLOPT_USERNAME,username.toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_PASSWORD,password.toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_TIMEOUT,RD_CURL_TIMEOUT);
curl_easy_setopt(curl,CURLOPT_FOLLOWLOCATION,1);
curl_easy_setopt(curl,CURLOPT_PROGRESSFUNCTION,DownloadProgressCallback);

2
lib/rddownload.h

@ -43,6 +43,8 @@ class RDDownload : public RDTransfer
int totalSteps() const;
RDDownload::ErrorCode runDownload(const QString &username,
const QString &password,
const QString &id_filename,
bool use_id_filename,
bool log_debug);
bool aborting() const;
static QString errorText(RDDownload::ErrorCode err);

44
lib/rdfeed.cpp

@ -466,6 +466,19 @@ void RDFeed::setPurgePassword(const QString &str) const
}
bool RDFeed::purgeUseIdFile() const
{
return RDBool(RDGetSqlValue("FEEDS","KEY_NAME",feed_keyname,
"PURGE_USE_ID_FILE").toString());
}
void RDFeed::setPurgeUseIdFile(bool state) const
{
SetRow("PURGE_USE_ID_FILE",RDYesNo(state));
}
RDRssSchemas::RssSchema RDFeed::rssSchema() const
{
return (RDRssSchemas::RssSchema)RDGetSqlValue("FEEDS","KEY_NAME",feed_keyname,
@ -844,12 +857,29 @@ bool RDFeed::postXml(QString *err_msg)
feed_xml=rssXml(err_msg,now).toUtf8();
feed_xml_ptr=0;
//
// Authentication
//
if((QUrl(feedUrl()).scheme().toLower()=="sftp")&&
(!rda->station()->sshIdentityFile().isEmpty())&&purgeUseIdFile()) {
curl_easy_setopt(curl,CURLOPT_USERNAME,
purgeUsername().toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_SSH_PRIVATE_KEYFILE,
rda->station()->sshIdentityFile().toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_KEYPASSWD,
purgePassword().toUtf8().constData());
}
else {
curl_easy_setopt(curl,CURLOPT_USERNAME,
purgeUsername().toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_PASSWORD,
purgePassword().toUtf8().constData());
}
curl_easy_setopt(curl,CURLOPT_URL,feedUrl().toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_UPLOAD,1);
curl_easy_setopt(curl,CURLOPT_READFUNCTION, __RDFeed_Readfunction_Callback);
curl_easy_setopt(curl,CURLOPT_READDATA,this);
curl_easy_setopt(curl,CURLOPT_USERNAME,purgeUsername().toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_PASSWORD,purgePassword().toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_TIMEOUT,RD_CURL_TIMEOUT);
curl_easy_setopt(curl,CURLOPT_NOPROGRESS,1);
@ -916,6 +946,8 @@ bool RDFeed::deleteXml(QString *err_msg)
}
conv->setTargetUrl(feedUrl());
conv_err=conv->runDelete(purgeUsername(),purgePassword(),
rda->station()->sshIdentityFile(),
purgeUseIdFile(),
rda->config()->logXloadDebugData());
*err_msg=RDDelete::errorText(conv_err);
delete conv;
@ -945,6 +977,8 @@ bool RDFeed::deleteImages(QString *err_msg)
}
conv->setTargetUrl(img_url);
conv_err=conv->runDelete(purgeUsername(),purgePassword(),
rda->station()->sshIdentityFile(),
purgeUseIdFile(),
rda->config()->logXloadDebugData());
*err_msg=RDDelete::errorText(conv_err);
delete conv;
@ -1039,6 +1073,8 @@ unsigned RDFeed::postCut(const QString &cutname,Error *err)
upload->setSourceFile(tmpfile);
upload->setDestinationUrl(purgeUrl()+"/"+cast->audioFilename());
switch((upload_err=upload->runUpload(purgeUsername(),purgePassword(),
rda->station()->sshIdentityFile(),
purgeUseIdFile(),
rda->config()->logXloadDebugData()))) {
case RDUpload::ErrorOk:
*err=RDFeed::ErrorOk;
@ -1165,6 +1201,8 @@ unsigned RDFeed::postFile(const QString &srcfile,Error *err)
upload->setSourceFile(tmpfile);
upload->setDestinationUrl(purgeUrl()+"/"+cast->audioFilename());
switch((upload_err=upload->runUpload(purgeUsername(),purgePassword(),
rda->station()->sshIdentityFile(),
purgeUseIdFile(),
rda->config()->logXloadDebugData()))) {
case RDUpload::ErrorOk:
sql=QString().sprintf("update PODCASTS set AUDIO_TIME=%u where ID=%u",
@ -1284,6 +1322,8 @@ unsigned RDFeed::postLog(const QString &logname,const QTime &start_time,
upload->setSourceFile(tmpfile);
upload->setDestinationUrl(purgeUrl()+"/"+cast->audioFilename());
switch((upload_err=upload->runUpload(purgeUsername(),purgePassword(),
rda->station()->sshIdentityFile(),
purgeUseIdFile(),
rda->config()->logXloadDebugData()))) {
case RDUpload::ErrorOk:
sql=QString().sprintf("update PODCASTS set AUDIO_TIME=%u where ID=%u",

2
lib/rdfeed.h

@ -92,6 +92,8 @@ class RDFeed : public QObject
void setPurgeUsername(const QString &str) const;
QString purgePassword() const;
void setPurgePassword(const QString &str) const;
bool purgeUseIdFile() const;
void setPurgeUseIdFile(bool state) const;
RDRssSchemas::RssSchema rssSchema() const;
void setRssSchema(RDRssSchemas::RssSchema schema) const;
QString headerXml() const;

2
lib/rdpodcast.cpp

@ -361,6 +361,8 @@ bool RDPodcast::removeAudio(RDFeed *feed,QString *err_text,bool log_debug) const
}
conv->setTargetUrl(url);
conv_err=conv->runDelete(feed->purgeUsername(),feed->purgePassword(),
rda->station()->sshIdentityFile(),
feed->purgeUseIdFile(),
rda->config()->logXloadDebugData());
*err_text=RDDelete::errorText(conv_err);
delete conv;

14
lib/rdrecording.cpp

@ -2,7 +2,7 @@
//
// Abstract a Rivendell Netcatch Recording.
//
// (C) Copyright 2002-2004,2016 Fred Gleason <fredg@paravelsystems.com>
// (C) Copyright 2002-2020 Fred Gleason <fredg@paravelsystems.com>
//
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License version 2 as
@ -616,6 +616,18 @@ void RDRecording::setUrlPassword(QString passwd) const
}
bool RDRecording::urlUseIdFile() const
{
return RDBool(GetStringValue("URL_PASSWORD"));
}
void RDRecording::setUrlUseIdFile(bool state) const
{
SetRow("URL_USE_ID_FILE",RDYesNo(state));
}
bool RDRecording::enableMetadata() const
{
return GetBoolValue("ENABLE_METADATA");

6
lib/rdrecording.h

@ -2,7 +2,7 @@
//
// Abstract a Rivendell RDCatch Event
//
// (C) Copyright 2002-2004,2016 Fred Gleason <fredg@paravelsystems.com>
// (C) Copyright 2002-2020 Fred Gleason <fredg@paravelsystems.com>
//
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License version 2 as
@ -131,6 +131,8 @@ class RDRecording
void setUrlUsername(QString name) const;
QString urlPassword() const;
void setUrlPassword(QString passwd) const;
bool urlUseIdFile() const;
void setUrlUseIdFile(bool state) const;
bool enableMetadata() const;
void setEnableMetadata(bool state) const;
int feedId() const;
@ -156,4 +158,4 @@ class RDRecording
};
#endif
#endif // RDRECORDING_H

13
lib/rdstation.cpp

@ -283,6 +283,19 @@ void RDStation::setBrowserPath(const QString &cmd) const
}
QString RDStation::sshIdentityFile() const
{
return RDGetSqlValue("STATIONS","NAME",station_name,"SSH_IDENTITY_FILE").
toString();
}
void RDStation::setSshIdentityFile(const QString &str) const
{
SetRow("SSH_IDENTITY_FILE",str);
}
RDStation::FilterMode RDStation::filterMode() const
{
return (RDStation::FilterMode)RDGetSqlValue("STATIONS","NAME",station_name,

2
lib/rdstation.h

@ -68,6 +68,8 @@ class RDStation
void setReportEditorPath(const QString &cmd);
QString browserPath() const;
void setBrowserPath(const QString &cmd) const;
QString sshIdentityFile() const;
void setSshIdentityFile(const QString &str) const;
RDStation::FilterMode filterMode() const;
void setFilterMode(RDStation::FilterMode mode) const;
bool startJack() const;

19
lib/rdupload.cpp

@ -112,6 +112,8 @@ int RDUpload::totalSteps() const
RDUpload::ErrorCode RDUpload::runUpload(const QString &username,
const QString &password,
const QString &id_filename,
bool use_id_filename,
bool log_debug)
{
CURL *curl=NULL;
@ -155,12 +157,25 @@ RDUpload::ErrorCode RDUpload::runUpload(const QString &username,
//
url.replace("#","%23");
//
// Authentication
//
if((conv_dst_url.scheme().toLower()=="sftp")&&
(!id_filename.isEmpty())&&use_id_filename) {
curl_easy_setopt(curl,CURLOPT_USERNAME,username.toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_SSH_PRIVATE_KEYFILE,
id_filename.toUtf8().constData());
curl_easy_setopt(curl,CURLOPT_KEYPASSWD,password.toUtf8().constData());
}
else {
strncpy(userpwd,(username+":"+password).utf8(),256);
curl_easy_setopt(curl,CURLOPT_USERPWD,userpwd);
}
curl_easy_setopt(curl,CURLOPT_URL,(const char *)url);
curl_easy_setopt(curl,CURLOPT_UPLOAD,1);
curl_easy_setopt(curl,CURLOPT_READDATA,f);
curl_easy_setopt(curl,CURLOPT_INFILESIZE,(long)conv_src_size);
strncpy(userpwd,(username+":"+password).utf8(),256);
curl_easy_setopt(curl,CURLOPT_USERPWD,userpwd);
curl_easy_setopt(curl,CURLOPT_TIMEOUT,RD_CURL_TIMEOUT);
curl_easy_setopt(curl,CURLOPT_PROGRESSFUNCTION,UploadProgressCallback);
curl_easy_setopt(curl,CURLOPT_PROGRESSDATA,this);

2
lib/rdupload.h

@ -42,6 +42,8 @@ class RDUpload : public RDTransfer
int totalSteps() const;
RDUpload::ErrorCode runUpload(const QString &username,
const QString &password,
const QString &id_filename,
bool use_id_filename,
bool log_debug);
bool aborting() const;
static QString errorText(RDUpload::ErrorCode err);

150
rdadmin/edit_feed.cpp

@ -234,6 +234,8 @@ EditFeed::EditFeed(const QString &feed,QWidget *parent)
//
feed_purge_url_edit=new QLineEdit(this);
feed_purge_url_edit->setMaxLength(191);
connect(feed_purge_url_edit,SIGNAL(textChanged(const QString &)),
this,SLOT(purgeUrlChangedData(const QString &)));
feed_purge_url_label=
new QLabel(feed_purge_url_edit,tr("Upload URL")+":",this);
feed_purge_url_label->setFont(labelFont());
@ -262,6 +264,16 @@ EditFeed::EditFeed(const QString &feed,QWidget *parent)
feed_purge_password_label->setFont(labelFont());
feed_purge_password_label->setAlignment(Qt::AlignRight|Qt::AlignVCenter);
//
// Purge Use Id File
//
feed_purge_use_id_file_check=new QCheckBox(this);
feed_purge_use_id_file_label=
new QLabel(feed_purge_use_id_file_check,
tr("Authenticate with local identity file"),this);
feed_purge_use_id_file_label->setFont(labelFont());
feed_purge_use_id_file_label->setAlignment(Qt::AlignLeft|Qt::AlignVCenter);
//
// Audio Format
//
@ -474,6 +486,8 @@ EditFeed::EditFeed(const QString &feed,QWidget *parent)
feed_purge_url_edit->setText(feed_feed->purgeUrl());
feed_purge_username_edit->setText(feed_feed->purgeUsername());
feed_purge_password_edit->setText(feed_feed->purgePassword());
feed_purge_use_id_file_check->setChecked(feed_feed->purgeUseIdFile());
purgeUrlChangedData(feed_purge_url_edit->text());
RDRssSchemas::RssSchema schema=feed_feed->rssSchema();
for(int i=0;i<feed_rss_schema_box->count();i++) {
if(feed_rss_schema_box->itemData(i).toInt()==schema) {
@ -547,6 +561,22 @@ void EditFeed::checkboxToggledData(bool state)
}
void EditFeed::purgeUrlChangedData(const QString &str)
{
QUrl url(str);
if((url.scheme().toLower()=="sftp")&&
(!rda->station()->sshIdentityFile().isEmpty())) {
feed_purge_use_id_file_check->setEnabled(true);
feed_purge_use_id_file_label->setEnabled(true);
}
else {
feed_purge_use_id_file_check->setDisabled(true);
feed_purge_use_id_file_label->setDisabled(true);
}
}
void EditFeed::lineeditChangedData(const QString &str)
{
UpdateControlState();
@ -667,6 +697,8 @@ void EditFeed::okData()
feed_feed->setPurgeUrl(feed_purge_url_edit->text());
feed_feed->setPurgeUsername(feed_purge_username_edit->text());
feed_feed->setPurgePassword(feed_purge_password_edit->text());
feed_feed->setPurgeUseIdFile(feed_purge_use_id_file_check->isChecked()&&
feed_purge_use_id_file_check->isEnabled());
feed_feed->
setRssSchema((RDRssSchemas::RssSchema)feed_rss_schema_box->
itemData(feed_rss_schema_box->currentIndex()).toUInt());
@ -710,82 +742,84 @@ void EditFeed::resizeEvent(QResizeEvent *e)
//
// Left-hand Side
//
feed_is_superfeed_box->setGeometry(115,13,60,19);
feed_is_superfeed_label->setGeometry(10,13,100,19);
feed_is_superfeed_button->setGeometry(185,13,140,38);
feed_is_superfeed_box->setGeometry(115,2,60,19);
feed_is_superfeed_label->setGeometry(10,2,100,19);
feed_is_superfeed_button->setGeometry(185,2,140,38);
feed_list_images_button->setGeometry(345,13,100,38);
feed_list_images_button->setGeometry(345,2,100,38);
feed_channel_section_groupbox->setGeometry(10,52,sizeHint().width()/2-10,377);
feed_channel_section_groupbox->setGeometry(10,41,sizeHint().width()/2-10,377);
feed_channel_title_edit->setGeometry(115,67,375,19);
feed_channel_title_label->setGeometry(20,67,90,19);
feed_channel_title_edit->setGeometry(115,56,375,19);
feed_channel_title_label->setGeometry(20,56,90,19);
feed_channel_category_box->setGeometry(115,89,375,19);
feed_channel_category_label->setGeometry(20,89,90,19);
feed_channel_category_box->setGeometry(115,78,375,19);
feed_channel_category_label->setGeometry(20,78,90,19);
feed_channel_link_edit->setGeometry(115,111,375,19);
feed_channel_link_label->setGeometry(20,111,90,19);
feed_channel_link_edit->setGeometry(115,100,375,19);
feed_channel_link_label->setGeometry(20,100,90,19);
feed_channel_copyright_edit->setGeometry(115,133,375,19);
feed_channel_copyright_label->setGeometry(20,133,90,19);
feed_channel_copyright_edit->setGeometry(115,122,375,19);
feed_channel_copyright_label->setGeometry(20,122,90,19);
feed_channel_editor_edit->setGeometry(115,155,375,19);
feed_channel_editor_label->setGeometry(20,155,90,19);
feed_channel_editor_edit->setGeometry(115,144,375,19);
feed_channel_editor_label->setGeometry(20,144,90,19);
feed_channel_author_edit->setGeometry(115,176,375,19);
feed_channel_author_label->setGeometry(20,176,90,19);
feed_channel_author_edit->setGeometry(115,166,375,19);
feed_channel_author_label->setGeometry(20,166,90,19);
feed_channel_author_is_default_check->setGeometry(120,197,15,15);
feed_channel_author_is_default_label->setGeometry(140,196,260,19);
feed_channel_author_is_default_check->setGeometry(120,186,15,15);
feed_channel_author_is_default_label->setGeometry(140,185,260,19);
feed_channel_explicit_check->setGeometry(205,198,15,15);
feed_channel_explicit_label->setGeometry(225,197,260,19);
feed_channel_explicit_check->setGeometry(205,187,15,15);
feed_channel_explicit_label->setGeometry(225,186,260,19);
feed_channel_owner_name_edit->setGeometry(115,220,375,19);
feed_channel_owner_name_label->setGeometry(20,220,90,19);
feed_channel_owner_name_edit->setGeometry(115,209,375,19);
feed_channel_owner_name_label->setGeometry(20,209,90,19);
feed_channel_owner_email_edit->setGeometry(115,242,375,19);
feed_channel_owner_email_label->setGeometry(20,242,90,19);
feed_channel_owner_email_edit->setGeometry(115,231,375,19);
feed_channel_owner_email_label->setGeometry(20,231,90,19);
feed_channel_webmaster_edit->setGeometry(115,264,375,19);
feed_channel_webmaster_label->setGeometry(20,264,90,19);
feed_channel_webmaster_edit->setGeometry(115,253,375,19);
feed_channel_webmaster_label->setGeometry(20,253,90,19);
feed_channel_language_edit->setGeometry(115,286,60,19);
feed_channel_language_label->setGeometry(20,286,90,19);
feed_channel_language_edit->setGeometry(115,275,60,19);
feed_channel_language_label->setGeometry(20,275,90,19);
feed_channel_explicit_check->setGeometry(205,288,15,15);
feed_channel_explicit_label->setGeometry(225,287,260,19);
feed_channel_explicit_check->setGeometry(205,277,15,15);
feed_channel_explicit_label->setGeometry(225,276,260,19);
feed_channel_description_edit->setGeometry(115,308,375,76);
feed_channel_description_label->setGeometry(20,308,90,19);
feed_channel_description_edit->setGeometry(115,297,375,76);
feed_channel_description_label->setGeometry(20,297,90,19);
feed_channel_image_box->setGeometry(115,386,375,38);
feed_channel_image_box->setGeometry(115,375,375,38);
feed_channel_image_box->setIconSize(QSize(36,36));
feed_channel_image_label->setGeometry(20,386,90,19);
feed_purge_url_edit->setGeometry(155,436,335,19);
feed_purge_url_label->setGeometry(20,436,130,19);
feed_purge_username_edit->setGeometry(225,458,95,19);
feed_purge_username_label->setGeometry(40,458,180,19);
feed_purge_password_edit->setGeometry(395,458,95,19);
feed_purge_password_label->setGeometry(320,458,70,19);
feed_format_edit->setGeometry(155,482,285,20);
feed_format_label->setGeometry(5,482,145,20);
feed_format_button->setGeometry(450,480,40,24);
feed_normalize_check->setGeometry(155,509,15,15);
feed_normalize_check_label->setGeometry(175,506,83,20);
feed_normalize_spin->setGeometry(295,506,40,20);
feed_normalize_label->setGeometry(245,506,45,20);
feed_normalize_unit_label->setGeometry(340,506,40,20);
feed_extension_edit->setGeometry(155,526,70,19);
feed_extension_label->setGeometry(20,526,130,19);
feed_base_url_edit->setGeometry(155,548,335,19);
feed_base_url_label->setGeometry(5,548,145,19);
feed_channel_image_label->setGeometry(20,375,90,19);
feed_purge_url_edit->setGeometry(155,425,335,19);
feed_purge_url_label->setGeometry(20,425,130,19);
feed_purge_username_edit->setGeometry(225,445,95,19);
feed_purge_username_label->setGeometry(40,445,180,19);
feed_purge_password_edit->setGeometry(395,445,95,19);
feed_purge_password_label->setGeometry(320,445,70,19);
feed_purge_use_id_file_check->setGeometry(160,466,15,15);
feed_purge_use_id_file_label->setGeometry(180,464,300,19);
feed_format_edit->setGeometry(155,485,285,20);
feed_format_label->setGeometry(5,485,145,20);
feed_format_button->setGeometry(450,483,40,24);
feed_normalize_check->setGeometry(160,510,15,15);
feed_normalize_check_label->setGeometry(180,507,83,20);
feed_normalize_spin->setGeometry(295,507,40,20);
feed_normalize_label->setGeometry(245,507,45,20);
feed_normalize_unit_label->setGeometry(340,507,40,20);
feed_extension_edit->setGeometry(155,529,70,19);
feed_extension_label->setGeometry(20,529,130,19);
feed_base_url_edit->setGeometry(155,551,335,19);
feed_base_url_label->setGeometry(5,551,145,19);
feed_autopost_box->setGeometry(155,573,60,19);
feed_autopost_label->setGeometry(5,573,145,19);

3
rdadmin/edit_feed.h

@ -52,6 +52,7 @@ class EditFeed : public RDDialog
void superfeedActivatedData(int n);
void schemaActivatedData(int n);
void checkboxToggledData(bool state);
void purgeUrlChangedData(const QString &str);
void lineeditChangedData(const QString &str);
void selectSubfeedsData();
void setFormatData();
@ -101,6 +102,8 @@ class EditFeed : public RDDialog
QLineEdit *feed_purge_username_edit;
QLabel *feed_purge_password_label;
QLineEdit *feed_purge_password_edit;
QCheckBox *feed_purge_use_id_file_check;
QLabel *feed_purge_use_id_file_label;
QLabel *feed_rss_schema_label;
QComboBox *feed_rss_schema_box;
QLabel *feed_header_xml_label;

140
rdadmin/edit_station.cpp

@ -158,6 +158,17 @@ EditStation::EditStation(QString sname,QWidget *parent)
station_web_browser_label->setFont(labelFont());
station_web_browser_label->setAlignment(Qt::AlignRight|Qt::AlignVCenter);
//
// ssh(1) Identity File
//
station_ssh_identity_file_edit=new QLineEdit(this);
station_ssh_identity_file_edit->setMaxLength(191);
station_ssh_identity_file_label=
new QLabel(station_ssh_identity_file_edit,tr("SSH Ident. File")+":",this);
station_ssh_identity_file_label->setFont(labelFont());
station_ssh_identity_file_label->
setAlignment(Qt::AlignRight|Qt::AlignVCenter);
//
// Station Time Offset
//
@ -474,6 +485,7 @@ EditStation::EditStation(QString sname,QWidget *parent)
station_audio_editor_edit->setText(station_station->editorPath());
station_report_editor_edit->setText(station_station->reportEditorPath());
station_web_browser_edit->setText(station_station->browserPath());
station_ssh_identity_file_edit->setText(station_station->sshIdentityFile());
station_timeoffset_box->setValue(station_station->timeOffset());
unsigned cartnum=station_station->startupCart();
if(cartnum>0) {
@ -708,6 +720,7 @@ void EditStation::okData()
setEditorPath(station_audio_editor_edit->text());
station_station->setReportEditorPath(station_report_editor_edit->text());
station_station->setBrowserPath(station_web_browser_edit->text());
station_station->setSshIdentityFile(station_ssh_identity_file_edit->text());
station_station->setTimeOffset(station_timeoffset_box->value());
cartnum=station_startup_cart_edit->text().toUInt(&ok);
if(ok&&(cartnum<=999999)) {
@ -896,102 +909,105 @@ void EditStation::stopCartClickedData()
void EditStation::resizeEvent(QResizeEvent *e)
{
station_name_edit->setGeometry(115,11,size().width()-120,19);
station_name_label->setGeometry(10,11,100,19);
station_name_edit->setGeometry(115,2,size().width()-120,19);
station_name_label->setGeometry(10,2,100,19);
station_short_name_edit->setGeometry(115,23,size().width()-120,19);
station_short_name_label->setGeometry(10,23,100,19);
station_short_name_edit->setGeometry(115,32,size().width()-120,19);
station_short_name_label->setGeometry(10,32,100,19);
station_description_edit->setGeometry(115,44,size().width()-120,19);
station_description_label->setGeometry(10,44,100,19);
station_description_edit->setGeometry(115,53,size().width()-120,19);
station_description_label->setGeometry(10,53,100,19);
station_default_name_edit->setGeometry(115,65,160,19);
station_default_name_label->setGeometry(10,65,100,19);
station_default_name_edit->setGeometry(115,74,160,19);
station_default_name_label->setGeometry(10,74,100,19);
station_address_edit->setGeometry(115,86,120,19);
station_address_label->setGeometry(10,86,100,19);
station_address_edit->setGeometry(115,95,120,19);
station_address_label->setGeometry(10,95,100,19);
station_audio_editor_edit->setGeometry(115,107,size().width()-120,19);
station_audio_editor_label->setGeometry(10,107,100,19);
station_audio_editor_edit->setGeometry(115,116,size().width()-120,19);
station_audio_editor_label->setGeometry(10,116,100,19);
station_report_editor_edit->setGeometry(115,128,size().width()-120,19);
station_report_editor_label->setGeometry(10,128,100,19);
station_report_editor_edit->setGeometry(115,137,size().width()-120,19);
station_report_editor_label->setGeometry(10,137,100,19);
station_web_browser_edit->setGeometry(115,149,size().width()-120,19);
station_web_browser_label->setGeometry(10,149,100,19);
station_web_browser_edit->setGeometry(115,158,size().width()-120,19);
station_web_browser_label->setGeometry(10,158,100,19);
station_ssh_identity_file_edit->setGeometry(115,170,size().width()-120,19);
station_ssh_identity_file_label->setGeometry(10,170,100,19);
station_timeoffset_box->setGeometry(115,179,80,19);
station_timeoffset_label->setGeometry(10,179,100,19);
station_timeoffset_box->setGeometry(115,191,80,19);
station_timeoffset_label->setGeometry(10,191,100,19);
station_startup_cart_edit->setGeometry(115,200,60,19);
station_startup_cart_label->setGeometry(10,200,100,19);
station_startup_select_button->setGeometry(180,199,50,22);
station_startup_cart_edit->setGeometry(115,212,60,19);
station_startup_cart_label->setGeometry(10,212,100,19);
station_startup_select_button->setGeometry(180,211,50,22);
station_cue_sel->setGeometry(90,221,110,117);
station_cue_sel_label->setGeometry(10,221,100,19);
station_cue_sel->setGeometry(90,243,110,117);
station_cue_sel_label->setGeometry(10,243,100,19);
station_start_cart_edit->setGeometry(290,221,60,20);
station_start_cart_label->setGeometry(205,221,80,20);
station_start_cart_button->setGeometry(355,220,50,22);
station_start_cart_edit->setGeometry(290,243,60,20);
station_start_cart_label->setGeometry(205,243,80,20);
station_start_cart_button->setGeometry(355,242,50,22);
station_stop_cart_edit->setGeometry(290,243,60,20);
station_stop_cart_label->setGeometry(205,243,80,20);
station_stop_cart_button->setGeometry(355,242,50,22);
station_stop_cart_edit->setGeometry(290,264,60,20);
station_stop_cart_label->setGeometry(205,264,80,20);
station_stop_cart_button->setGeometry(355,263,50,22);
station_heartbeat_box->setGeometry(10,268,15,15);
station_heartbeat_label->setGeometry(30,266,150,20);
station_heartbeat_box->setGeometry(10,290,15,15);
station_heartbeat_label->setGeometry(30,285,150,20);
station_filter_box->setGeometry(210,268,15,15);
station_filter_label->setGeometry(230,266,150,20);
station_filter_box->setGeometry(210,290,15,15);
station_filter_label->setGeometry(230,285,150,20);
station_hbcart_edit->setGeometry(65,290,60,19);
station_hbcart_label->setGeometry(10,290,50,19);
station_hbcart_button->setGeometry(140,287,60,26);
station_hbcart_edit->setGeometry(65,310,60,19);
station_hbcart_label->setGeometry(10,310,50,19);
station_hbcart_button->setGeometry(140,307,60,26);
station_hbinterval_spin->setGeometry(275,290,45,19);
station_hbinterval_label->setGeometry(220,290,50,19);
station_hbinterval_unit->setGeometry(325,290,100,19);
station_hbinterval_spin->setGeometry(275,310,45,19);
station_hbinterval_label->setGeometry(220,310,50,19);
station_hbinterval_unit->setGeometry(325,310,100,19);
station_maint_box->setGeometry(10,317,15,15);
station_maint_label->setGeometry(30,315,size().width()-40,20);
station_maint_box->setGeometry(10,335,15,15);
station_maint_label->setGeometry(30,333,size().width()-40,20);
station_dragdrop_box->setGeometry(10,338,15,15);
station_dragdrop_label->setGeometry(30,335,size().width()-40,20);
station_dragdrop_box->setGeometry(10,356,15,15);
station_dragdrop_label->setGeometry(30,353,size().width()-40,20);
station_panel_enforce_box->setGeometry(25,356,15,15);
station_panel_enforce_label->setGeometry(45,356,size().width()-55,20);
station_panel_enforce_box->setGeometry(25,374,15,15);
station_panel_enforce_label->setGeometry(45,374,size().width()-55,20);
station_systemservices_groupbox->setGeometry(10,381,size().width()-20,60);
station_systemservices_groupbox->setGeometry(10,395,size().width()-20,60);
station_http_station_box->setGeometry(145,396,size().width()-165,19);
station_http_station_label->setGeometry(11,396,130,19);
station_http_station_box->setGeometry(145,410,size().width()-165,19);
station_http_station_label->setGeometry(11,408,130,19);
station_cae_station_box->setGeometry(145,417,size().width()-165,19);
station_cae_station_label->setGeometry(11,417,130,19);
station_cae_station_box->setGeometry(145,431,size().width()-165,19);
station_cae_station_label->setGeometry(11,431,130,19);
station_rdlibrary_button->setGeometry(30,455,80,50);
station_rdlibrary_button->setGeometry(30,461,80,50);
station_rdcatch_button->setGeometry(120,455,80,50);
station_rdcatch_button->setGeometry(120,461,80,50);
station_rdairplay_button->setGeometry(210,455,80,50);
station_rdairplay_button->setGeometry(210,461,80,50);
station_rdpanel_button->setGeometry(300,455,80,50);
station_rdpanel_button->setGeometry(300,461,80,50);
station_rdlogedit_button->setGeometry(30,513,80,50);
station_rdlogedit_button->setGeometry(30,519,80,50);
station_rdcartslots_button->setGeometry(120,513,80,50);
station_rdcartslots_button->setGeometry(120,519,80,50);
station_dropboxes_button->setGeometry(210,513,80,50);
station_dropboxes_button->setGeometry(210,519,80,50);
station_switchers_button->setGeometry(300,513,80,50);
station_switchers_button->setGeometry(300,519,80,50);
station_hostvars_button->setGeometry(30,575,80,50);
station_hostvars_button->setGeometry(30,577,80,50);
station_audioports_button->setGeometry(120,575,80,50);
station_audioports_button->setGeometry(120,577,80,50);
station_ttys_button->setGeometry(210,575,80,50);
station_ttys_button->setGeometry(210,577,80,50);
station_adapters_button->setGeometry(300,575,80,50);
station_adapters_button->setGeometry(300,577,80,50);
station_jack_button->setGeometry(120,635,80,50);

2
rdadmin/edit_station.h

@ -94,6 +94,8 @@ class EditStation : public RDDialog
QLineEdit *station_report_editor_edit;
QLabel *station_web_browser_label;
QLineEdit *station_web_browser_edit;
QLabel *station_ssh_identity_file_label;
QLineEdit *station_ssh_identity_file_edit;
QLabel *station_timeoffset_label;
QSpinBox *station_timeoffset_box;
QLabel *station_startup_cart_label;

18
rdadmin/list_images.cpp

@ -128,6 +128,8 @@ void ListImages::addData()
img_id,f0.last()),
list_feed->purgeUsername(),
list_feed->purgePassword(),
rda->station()->sshIdentityFile(),
list_feed->purgeUseIdFile(),
&err_msg)){
QMessageBox::warning(this,"RDAdmin - "+tr("Upload Error"),
tr("Image upload failed!")+"\n"+
@ -192,7 +194,9 @@ void ListImages::deleteData()
list_model->imageId(row),
q->value(0).toString()),
list_feed->purgeUsername(),
list_feed->purgePassword(),&err_msg)) {
list_feed->purgePassword(),
rda->station()->sshIdentityFile(),
list_feed->purgeUseIdFile(),&err_msg)) {
if(QMessageBox::information(this,"RDAdmin - "+tr("Delete Error"),
tr("Unable to delete remote file!")+"\n"+
"["+err_msg+"].\n"+
@ -276,7 +280,9 @@ int ListImages::SelectedRow() const
bool ListImages::UploadRemoteImage(const QString &filename,const QString &url,
const QString &username,
const QString &password,QString *err_msg)
const QString &password,
const QString &id_filename,bool use_id_file,
QString *err_msg)
{
RDUpload::ErrorCode err_code;
RDUpload *upload=new RDUpload(rda->config(),this);
@ -286,7 +292,7 @@ bool ListImages::UploadRemoteImage(const QString &filename,const QString &url,
0,upload->totalSteps(),this);
pd->setWindowTitle("RDAdmin");
connect(upload,SIGNAL(progressChanged(int)),pd,SLOT(setValue(int)));
err_code=upload->runUpload(username,password,false);
err_code=upload->runUpload(username,password,id_filename,use_id_file,false);
delete pd;
delete upload;
@ -295,13 +301,15 @@ bool ListImages::UploadRemoteImage(const QString &filename,const QString &url,
bool ListImages::DeleteRemoteImage(const QString &url,const QString &username,
const QString &password,QString *err_msg)
const QString &password,
const QString &id_filename,bool use_id_file,
QString *err_msg)
{
RDDelete::ErrorCode err_code;
RDDelete *del=new RDDelete(rda->config(),this);
del->setTargetUrl(url);
err_code=del->runDelete(username,password,false);
err_code=del->runDelete(username,password,id_filename,use_id_file,false);
*err_msg=RDDelete::errorText(err_code);
delete del;

4
rdadmin/list_images.h

@ -58,9 +58,11 @@ class ListImages : public RDDialog
int SelectedRow() const;
bool UploadRemoteImage(const QString &filename,const QString &url,
const QString &username,const QString &password,
const QString &id_filename,bool use_id_file,
QString *err_msg);
bool DeleteRemoteImage(const QString &url,const QString &username,
const QString &password,QString *err_msg);
const QString &password,const QString &id_filename,
bool use_id_file,QString *err_msg);
EditImage *list_edit_image_dialog;
QListView *list_view;
RDImagePickerModel *list_model;

8
rdadmin/rdadmin_cs.ts

@ -1714,6 +1714,10 @@ Clipboard</source>
<source>Use as default Item Author</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Authenticate with local identity file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditFeedPerms</name>
@ -4085,6 +4089,10 @@ Instances</source>
<source>Web Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SSH Ident. File</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditSvc</name>

8
rdadmin/rdadmin_de.ts

@ -1549,6 +1549,10 @@ Clipboard</source>
<source>Use as default Item Author</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Authenticate with local identity file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditFeedPerms</name>
@ -3894,6 +3898,10 @@ Instances</source>
<source>Web Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SSH Ident. File</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditSvc</name>

8
rdadmin/rdadmin_es.ts

@ -1713,6 +1713,10 @@ Clipboard</source>
<source>Use as default Item Author</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Authenticate with local identity file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditFeedPerms</name>
@ -4090,6 +4094,10 @@ Instances</source>
<source>Web Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SSH Ident. File</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditSvc</name>

8
rdadmin/rdadmin_fr.ts

@ -1217,6 +1217,10 @@ Clipboard</source>
<source>Use as default Item Author</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Authenticate with local identity file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditFeedPerms</name>
@ -3268,6 +3272,10 @@ Instances</source>
<source>Web Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SSH Ident. File</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditSvc</name>

8
rdadmin/rdadmin_nb.ts

@ -1515,6 +1515,10 @@ Clipboard</source>
<source>Use as default Item Author</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Authenticate with local identity file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditFeedPerms</name>
@ -3815,6 +3819,10 @@ Instances</source>
<source>Web Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SSH Ident. File</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditSvc</name>

8
rdadmin/rdadmin_nn.ts

@ -1515,6 +1515,10 @@ Clipboard</source>
<source>Use as default Item Author</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Authenticate with local identity file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditFeedPerms</name>
@ -3815,6 +3819,10 @@ Instances</source>
<source>Web Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SSH Ident. File</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditSvc</name>

8
rdadmin/rdadmin_pt_BR.ts

@ -1525,6 +1525,10 @@ Clipboard</source>
<source>Use as default Item Author</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Authenticate with local identity file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditFeedPerms</name>
@ -3886,6 +3890,10 @@ Instances</source>
<source>Web Browser</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SSH Ident. File</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>EditSvc</name>

10
rdcatchd/batch.cpp

@ -212,7 +212,10 @@ void MainObject::RunDownload(CatchEvent *evt)
url_username=RD_ANON_FTP_USERNAME;
url_password=QString(RD_ANON_FTP_PASSWORD)+"-"+VERSION;
}
switch((conv_err=conv->runDownload(url_username,url_password,
//
// FIXME: Finish implementing public key support!
//
switch((conv_err=conv->runDownload(url_username,url_password,"",false,
rda->config()->logXloadDebugData()))) {
case RDDownload::ErrorOk:
rda->syslog(LOG_INFO,"finished download of %s to %s, id=%d",
@ -324,7 +327,10 @@ void MainObject::RunUpload(CatchEvent *evt)
url_username=RD_ANON_FTP_USERNAME;
url_password=QString(RD_ANON_FTP_PASSWORD)+"-"+VERSION;
}
switch((conv_err=conv->runUpload(url_username,url_password,
//
// FIXME: Finish implementing ssh(1) identity keys!
//
switch((conv_err=conv->runUpload(url_username,url_password,"",false,
rda->config()->logXloadDebugData()))) {
case RDUpload::ErrorOk:
catch_connect->setExitCode(evt->id(),RDRecording::Ok,tr("Ok"));

10
rdrepld/citadelxds.cpp

@ -369,8 +369,11 @@ bool CitadelXds::PostCut(const QString &cutname,const QString &filename)
RDUpload *upload=new RDUpload(rda->config());
upload->setSourceFile(tempfile);
upload->setDestinationUrl(config()->url()+"/"+filename);
//
// FIXME: Finish implementing ssh(1) id keys!
//
switch(upload_err=upload->runUpload(config()->urlUsername(),
config()->urlPassword(),
config()->urlPassword(),"",false,
rda->config()->logXloadDebugData())) {
case RDUpload::ErrorOk:
break;
@ -420,8 +423,11 @@ void CitadelXds::PurgeCuts()
Q3Url url(path+q->value(1).toString());
conv=new RDDelete(rda->config());
conv->setTargetUrl(url);
//
// FIXME: Finish implementing ssh(1) key support!
//
if((conv_err=conv->runDelete(config()->urlUsername(),
config()->urlPassword(),
config()->urlPassword(),"",false,
rda->config()->logXloadDebugData()))==
RDDelete::ErrorOk) {
sql=QString().sprintf("delete from REPL_CART_STATE where ID=%d",

12
tests/delete_test.cpp

@ -36,6 +36,7 @@ MainObject::MainObject(QObject *parent)
username="";
password="";
RDDelete::ErrorCode conv_err;
use_identity_file=false;
//
// Open the Database
@ -58,6 +59,14 @@ MainObject::MainObject(QObject *parent)
password=rda->cmdSwitch()->value(i);
rda->cmdSwitch()->setProcessed(i,true);
}
if(rda->cmdSwitch()->key(i)=="--ssh-identity-filename") {
ssh_identity_filename=rda->cmdSwitch()->value(i);
rda->cmdSwitch()->setProcessed(i,true);
}
if(rda->cmdSwitch()->key(i)=="--use-identity-file") {
use_identity_file=true;