code
stringlengths
1
1.05M
repo_name
stringlengths
6
83
path
stringlengths
3
242
language
stringclasses
222 values
license
stringclasses
20 values
size
int64
1
1.05M
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/PutLiveChannelRequest.cc
C++
apache-2.0
5,712
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/model/PutLiveChannelResult.cc
C++
apache-2.0
2,352
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/model/PutLiveChannelStatusRequest.cc
C++
apache-2.0
1,898
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/model/PutObjectByUrlRequest.cc
C++
apache-2.0
1,697
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless re...
YifuLiu/AliOS-Things
components/oss/src/model/PutObjectRequest.cc
C++
apache-2.0
3,724
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/PutObjectResult.cc
C++
apache-2.0
1,787
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/model/RestoreObjectRequest.cc
C++
apache-2.0
1,794
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless re...
YifuLiu/AliOS-Things
components/oss/src/model/RestoreObjectResult.cc
C++
apache-2.0
924
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/model/SelectObjectRequest.cc
C++
apache-2.0
11,028
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketAclRequest.cc
C++
apache-2.0
1,358
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketCorsRequest.cc
C++
apache-2.0
4,167
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketEncryptionRequest.cc
C++
apache-2.0
2,003
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketInventoryConfigurationRequest.cc
C++
apache-2.0
4,832
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketLifecycleRequest.cc
C++
apache-2.0
5,826
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketLoggingRequest.cc
C++
apache-2.0
2,332
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketPaymentRequest.cc
C++
apache-2.0
1,703
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketPolicyRequest.cc
C++
apache-2.0
1,316
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketQosInfoRequest.cc
C++
apache-2.0
2,806
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketRefererRequest.cc
C++
apache-2.0
2,224
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketStorageCapacityRequest.cc
C++
apache-2.0
1,895
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketTaggingRequest.cc
C++
apache-2.0
2,437
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketVersioningRequest.cc
C++
apache-2.0
1,645
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/SetBucketWebsiteRequest.cc
C++
apache-2.0
2,597
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/model/SetObjectAclRequest.cc
C++
apache-2.0
1,656
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless re...
YifuLiu/AliOS-Things
components/oss/src/model/SetObjectAclResult.cc
C++
apache-2.0
921
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/SetObjectTaggingRequest.cc
C++
apache-2.0
2,642
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/Tagging.cc
C++
apache-2.0
1,201
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/model/UploadPartCopyRequest.cc
C++
apache-2.0
6,707
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/model/UploadPartCopyResult.cc
C++
apache-2.0
2,513
/* * Copyright 2009-2018 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/model/UploadPartRequest.cc
C++
apache-2.0
3,730
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #include "OssClient.h" #include "iostream" #include "fstream" #include "string.h" #include "oss_app.h" #if !ESP_PLATFORM #include "aos/vfs.h" #endif #include "fcntl.h" #ifdef USE_SD_FOR_OSS #include <stdio.h> #include <stdlib.h> #include <string.h> #incl...
YifuLiu/AliOS-Things
components/oss/src/oss_app.cpp
C++
apache-2.0
16,199
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef SSH_ERLANGSHEN_OSS_APP_H #define SSH_ERLANGSHEN_OSS_APP_H #include <string.h> #ifdef __cplusplus extern "C" { #endif char *oss_upload_local_file(char *keyId, char *keySecret, char *endPoint, char *bucketName, char *localfilepath); char *oss_uplo...
YifuLiu/AliOS-Things
components/oss/src/oss_app.h
C
apache-2.0
839
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless re...
YifuLiu/AliOS-Things
components/oss/src/resumable/DownloadObjectRequest.cc
C++
apache-2.0
4,907
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless re...
YifuLiu/AliOS-Things
components/oss/src/resumable/MultiCopyObjectRequest.cc
C++
apache-2.0
6,859
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/resumable/ResumableBaseWorker.cc
C++
apache-2.0
2,780
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/resumable/ResumableBaseWorker.h
C++
apache-2.0
1,629
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/resumable/ResumableCopier.cc
C++
apache-2.0
14,174
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless re...
YifuLiu/AliOS-Things
components/oss/src/resumable/ResumableCopier.h
C++
apache-2.0
1,874
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless re...
YifuLiu/AliOS-Things
components/oss/src/resumable/ResumableDownloader.cc
C++
apache-2.0
17,623
#pragma once /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unles...
YifuLiu/AliOS-Things
components/oss/src/resumable/ResumableDownloader.h
C++
apache-2.0
2,274
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/resumable/ResumableUploader.cc
C++
apache-2.0
15,480
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/resumable/ResumableUploader.h
C++
apache-2.0
2,419
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/resumable/UploadObjectRequest.cc
C++
apache-2.0
6,120
/* Crc64.cc -- compute CRC-64 * Copyright (C) 2013 Mark Adler * Version 1.4 16 Dec 2013 Mark Adler */ /* This software is provided 'as-is', without any express or implied warranty. In no event will the author be held liable for any damages arising from the use of this software. Permission is granted to ...
YifuLiu/AliOS-Things
components/oss/src/utils/Crc32.cc
C++
apache-2.0
5,080
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/utils/Crc32.h
C++
apache-2.0
843
/* Crc64.cc -- compute CRC-64 * Copyright (C) 2013 Mark Adler * Version 1.4 16 Dec 2013 Mark Adler */ /* This software is provided 'as-is', without any express or implied warranty. In no event will the author be held liable for any damages arising from the use of this software. Permission is granted to ...
YifuLiu/AliOS-Things
components/oss/src/utils/Crc64.cc
C++
apache-2.0
8,888
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/utils/Crc64.h
C++
apache-2.0
999
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by...
YifuLiu/AliOS-Things
components/oss/src/utils/Executor.cc
C++
apache-2.0
772
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/utils/FileSystemUtils.cc
C++
apache-2.0
6,312
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/utils/FileSystemUtils.h
C++
apache-2.0
1,911
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicab...
YifuLiu/AliOS-Things
components/oss/src/utils/LogUtils.cc
C++
apache-2.0
3,908
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicab...
YifuLiu/AliOS-Things
components/oss/src/utils/LogUtils.h
C++
apache-2.0
1,442
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicab...
YifuLiu/AliOS-Things
components/oss/src/utils/Runnable.cc
C++
apache-2.0
801
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/utils/SignUtils.cc
C++
apache-2.0
3,981
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/utils/SignUtils.h
C++
apache-2.0
1,453
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless...
YifuLiu/AliOS-Things
components/oss/src/utils/StreamBuf.h
C++
apache-2.0
3,458
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicab...
YifuLiu/AliOS-Things
components/oss/src/utils/ThreadExecutor.cc
C++
apache-2.0
2,381
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicab...
YifuLiu/AliOS-Things
components/oss/src/utils/ThreadExecutor.h
C++
apache-2.0
1,119
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/utils/Utils.cc
C++
apache-2.0
39,021
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
YifuLiu/AliOS-Things
components/oss/src/utils/Utils.h
C++
apache-2.0
5,419
#include <stdlib.h> #include <string.h> #include <stdint.h> #include <aos/flashpart.h> #include <aos/hal/flash.h> #include "ota_log.h" #include "ota_import.h" #include "ota_hal_os.h" int ota_is_download_mode(void) { int ret = 0; ota_boot_param_t param = { 0, }; memset(&param, 0, sizeof(ota_boot_param_t)); ...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_aos_param.c
C
apache-2.0
6,012
#include <string.h> #include <stdlib.h> #include <stdint.h> #include <aos/flashpart.h> #include <aos/hal/flash.h> #include "ota_log.h" #include "ota_hal.h" #include "ota_import.h" #include "ota_hal_os.h" unsigned char *ota_cache = NULL; unsigned int ota_cache_len = 0; unsigned int ota_fw_size ...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_aos_plat.c
C
apache-2.0
9,749
/* * Copyright (C) 2015-2020 Alibaba Group Holding Limited */ #include <stdio.h> #include <string.h> #include <stdlib.h> #include <unistd.h> #include <errno.h> #include <fcntl.h> #include "ota_log.h" #include "ota_import.h" #include "ota_hal_os.h" #include "ota_hal_digest.h" #include "ota_hal.h" static ota_hash_ctx...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_ctrl.c
C
apache-2.0
6,889
/* * Copyright (C) 2015-2017 Alibaba Group Holding Limited */ #include <stdlib.h> #include <string.h> #include "ota_log.h" #include "ota_import.h" #include "ota_hal_digest.h" #include "mbedtls/sha256.h" #include "mbedtls/md5.h" #include "mbedtls/bignum.h" #include "mbedtls/rsa.h" /* RSA Public Key:User needs sign i...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_digest.c
C
apache-2.0
3,603
/**@defgroup ota_hal_digest_api * @{ * This is an include file of OTA verify interface. * * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef OTA_HAL_DIGEST_H #define OTA_HAL_DIGEST_H #include "ota_agent.h" #ifdef __cplusplus extern "C" { #endif /***************************************************...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_digest.h
C
apache-2.0
4,743
#include <stdio.h> #include <string.h> #include <stdlib.h> #include <unistd.h> #include <errno.h> #include <fcntl.h> #include "ota_log.h" #include "ota_import.h" #include "ota_hal_os.h" #include "ota_hal.h" #include "upack_data_file.h" OTA_WEAK int ota_fopen(const char *filename, int mode) { int fd = -1; if (f...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_fs_plat.c
C
apache-2.0
885
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #include <stdlib.h> #include <sys/time.h> #include <time.h> #include <signal.h> #include <string.h> #include "aos/kernel.h" #include "ota_log.h" #include "ota_hal_os.h" #ifdef OTA_LINUX #include <unistd.h> #include <pthread.h> #include <sys/reboot.h> #el...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_os.c
C
apache-2.0
6,130
/** @defgroup ota_hal_os_api * @{ * * This is an include file of OTA OS adapt interface. * * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef OTA_HAL_OS_H #define OTA_HAL_OS_H #ifdef __cplusplus extern "C" { #endif #define ota_snprintf snprintf /*memory*/ void ota_free(void *ptr); void *ota_ma...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_os.h
C
apache-2.0
1,287
#include <stdlib.h> #include <string.h> #include <stdint.h> #include "ota_log.h" #include "ota_import.h" #include "ota_hal_os.h" #include "aos_hal_flash.h" static int boot_part = HAL_PARTITION_OTA_TEMP; int ota_is_download_mode(void) { int ret = 0; ota_boot_param_t param = {0}; memset(&param...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_param.c
C
apache-2.0
5,864
#include <string.h> #include <stdlib.h> #include <stdint.h> #include "ota_log.h" #include "ota_import.h" #include "ota_hal_os.h" #include "ota_hal.h" #include "aos_hal_flash.h" unsigned char *ota_cache = NULL; unsigned int ota_cache_len = 0; unsigned int ota_fw_size = 0; unsigned int ota_re...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_plat.c
C
apache-2.0
6,485
/* * Copyright (C) 2015-2017 Alibaba Group Holding Limited */ #include <stdlib.h> #include "ota_hal_trans.h" #include "aiot_mqtt_api.h" /*MQTT API*/ int ota_hal_mqtt_publish(void *mqtt_client, char *topic, int qos, void *data, int len) { return aiot_mqtt_pub(mqtt_client, topic, data, len, qos); } int ota_hal_m...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_trans.c
C
apache-2.0
890
/** @defgroup ota_hal_transport_api * @{ * * This is an include file of OTA transport interface. * * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef OTA_HAL_TRANSPORT_H #define OTA_HAL_TRANSPORT_H #ifdef __cplusplus extern "C" { #endif /*MQTT*/ typedef struct { unsigned short packet_id; ...
YifuLiu/AliOS-Things
components/ota/hal/ota_hal_trans.h
C
apache-2.0
1,108
/** @defgroup ota_agent_api * @{ * * This is an include file of OTA agent transporting with clould. * * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef OTA_AGENT_H #define OTA_AGENT_H /******************************************************************* *********** OTA Agent ...
YifuLiu/AliOS-Things
components/ota/include/ota_agent.h
C
apache-2.0
23,309
/** @defgroup ota_hal_api * @{ * * This is an include file of OTA HAL interface. * * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef OTA_HAL_H #define OTA_HAL_H #include "ota_agent.h" #ifdef __cplusplus extern "C" { #endif /** * ota_hal_init ota hal init main OTA partition. * * @param[in] ...
YifuLiu/AliOS-Things
components/ota/include/ota_hal.h
C
apache-2.0
3,158
/** @defgroup ota_internal_api * @{ * * This is an include file of OTA internal interface. * * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef OTA_API_H #define OTA_API_H #include "ota_agent.h" #ifdef __cplusplus extern "C" { #endif #define OTA_INFO (UAGENT_FUNC_USER_BASE) /* ota proc...
YifuLiu/AliOS-Things
components/ota/include/ota_import.h
C
apache-2.0
4,746
/** @defgroup ota_log_api * @{ * * This is an include file of OTA log interface. * * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef OTA_LOG_H #define OTA_LOG_H #include <stdarg.h> #include <stdio.h> #include "ulog/ulog.h" #ifdef __cplusplus extern "C" { #endif #define OTA_LOG_D(fmt, ...) LOGD(...
YifuLiu/AliOS-Things
components/ota/include/ota_log.h
C
apache-2.0
581
/* *@defgroup ota_updater_api * @{ * * This is an include file of OTA updater to install new Firmware. * * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef OTA_UPDATE_H #define OTA_UPDATE_H #include "ota_agent.h" #ifdef __cplusplus extern "C" { #endif /** * ENUM: OTA Updater ERRNO. */ typedef...
YifuLiu/AliOS-Things
components/ota/include/ota_updater.h
C
apache-2.0
4,484
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #include <unistd.h> #include <string.h> #include <stdlib.h> #include <fcntl.h> #include "ota_log.h" #include "ota_hal_os.h" #include "ota_import.h" #include "ota_hal_trans.h" #include "httpclient.h" int ota_get_upgrade_status(void); void ota_set_upgrade_s...
YifuLiu/AliOS-Things
components/ota/ota_agent/download/ota_download_file2fs_http.c
C
apache-2.0
6,502
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #include <unistd.h> #include <string.h> #include <stdlib.h> #include "ota_log.h" #include "ota_hal_os.h" #include "ota_import.h" #include "ota_hal_trans.h" #include "httpclient.h" static int ota_upgrading = 0; static unsigned char dl_buf[OTA_DOWNLOAD_BLO...
YifuLiu/AliOS-Things
components/ota/ota_agent/download/ota_download_http.c
C
apache-2.0
17,268
/* *Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #include <string.h> #include "ota_log.h" #include "ota_import.h" #include "ota_hal_os.h" #include "ota_hal.h" #ifdef AOS_COMP_PWRMGMT #include "aos/pwrmgmt.h" #endif #if !defined(OTA_LINUX) && defined OTA_CONFIG_SECURE_DL_MODE static wdg_dev_t ota_wdg = {...
YifuLiu/AliOS-Things
components/ota/ota_agent/ota_service.c
C
apache-2.0
13,160
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #include <string.h> #include <cJSON.h> #include <stdlib.h> #include "ota_log.h" #include "ota_hal.h" #include "ota_import.h" #include "ota_hal_os.h" #include "ota_hal_trans.h" #include "ota_agent.h" /** * ota_sevice_parse_msg OTA parse download info fro...
YifuLiu/AliOS-Things
components/ota/ota_agent/transport/ota_transport_mqtt.c
C
apache-2.0
17,649
/* * Copyright (C) 2015-2017 Alibaba Group Holding Limited */ #include <string.h> #include "ota_log.h" #include "ota_import.h" #include "ota_hal_digest.h" #include "ota_hal_os.h" #define OTA_BUF_VERIFY 512 int ota_hash_init(ota_hash_ctx_t *ctx, unsigned char type) { int ret = 0; if (ctx == NULL) { O...
YifuLiu/AliOS-Things
components/ota/ota_agent/verify/ota_verify_hash.c
C
apache-2.0
6,980
/* * Copyright (C) 2015-2018 Alibaba Group Holding Limited */ #include "string.h" #include "ota_log.h" #include "ota_import.h" #include "ota_hal_digest.h" #include "ota_hal_os.h" static char ota_get_sign_hash_method(void) { return OTA_SHA256; } static int ota_verify_rsa_hash(unsigned char *src, int src_len, uns...
YifuLiu/AliOS-Things
components/ota/ota_agent/verify/ota_verify_rsa.c
C
apache-2.0
3,409
#! /usr/bin/env python import os, sys, re, struct, getopt from sys import platform import array,hashlib,struct def print_usage(): print("") print("Usage:" + sys.argv[0]) print(sys.argv[0] + " main_bin mcu_bin offset magic") print(" [-h | --help] Display usage") sys.stdout.flush() def write_file(file_name, gap_s...
YifuLiu/AliOS-Things
components/ota/tools/ota_image_package.py
Python
apache-2.0
2,426
#include <stdio.h> #include <string.h> #include <stdlib.h> #include <unistd.h> #include <errno.h> #include <string.h> #include <fcntl.h> #include "upack_data_file.h" #include "ota_log.h" #include "ota_import.h" int data_file_unpack(void *pack_file, unsigned int pack_size, void *upack_path) { int ret = -1; int ...
YifuLiu/AliOS-Things
components/ota/tools/upack_data_file.c
C
apache-2.0
5,658
/** @defgroup upack_data_file * @{ * * This is an include file of upack js app.bin interface. * * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef UPACK_DATA_FILE_H #define UPACK_DATA_FILE_H #ifdef __cplusplus extern "C" { #endif typedef struct DATA_FILE_PACK_HEAD { unsigned short file_numb;...
YifuLiu/AliOS-Things
components/ota/tools/upack_data_file.h
C
apache-2.0
988
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #include <stddef.h> #include <fcntl.h> #include <sys/stat.h> #include <utime.h> #include <string.h> #include "esp_vfs.h" #define VFS_PATH_MAX 256 static char g_current_working_directory[VFS_PATH_MAX] = "/"; #if ESP_IDF_VERSION <= ESP_IDF_VERSION_VAL(4, 2...
YifuLiu/AliOS-Things
components/posix/esp_idf/fs.c
C
apache-2.0
925
/* * Copyright (C) 2021 Alibaba Group Holding Limited */ #ifndef _SYS_STATFS_H #define _SYS_STATFS_H #ifdef __cplusplus extern "C" { #endif struct statfs { long f_type; /* fs type */ long f_bsize; /* optimized transport block size */ long f_blocks; /* total blocks */ long f_bfree; /* availa...
YifuLiu/AliOS-Things
components/posix/esp_idf/include/sys/statfs.h
C
apache-2.0
698
/* * Copyright (C) 2021 Alibaba Group Holding Limited */ #include <stdio.h> #include <pthread.h> #if AOS_COMP_CLI #include "aos/cli.h" #endif static int count = 0; static pthread_mutex_t count_lock = PTHREAD_MUTEX_INITIALIZER; static int ret_value = 0; static void *new_thread_func(void *arg) { int increase_co...
YifuLiu/AliOS-Things
components/posix/example/pthread_example.c
C
apache-2.0
1,859
#include "dm_export.h" #include <stdio.h> #include <stdlib.h> #include <stdbool.h> #include <sys/types.h> #include <sys/stat.h> #include <sys/ioctl.h> #include <sys/time.h> #include <fcntl.h> #include <string.h> #include <unistd.h> #include <errno.h> SYMBOL_EXPORT(printf); SYMBOL_EXPORT(memmove); SYMBOL_EXPORT(malloc);...
YifuLiu/AliOS-Things
components/posix/export.c
C
apache-2.0
876
/* * Copyright (C) 2018-2020 Alibaba Group Holding Limited */ #ifndef _DIRENT_H #define _DIRENT_H #ifdef __cplusplus extern "C" { #endif #include <stdint.h> #include <sys/stat.h> #include <aos/vfs.h> /* file types. */ #define DT_UNKNOWN 0 #define DT_FIFO 1 #define DT_CHR 2 #define DT_DIR 4 #define DT_B...
YifuLiu/AliOS-Things
components/posix/include/dirent.h
C
apache-2.0
1,103
/* * Copyright (C) 2015-2020 Alibaba Group Holding Limited */ #ifndef _ENVIRO_H #define _ENVIRO_H #ifdef __cplusplus extern "C" { #endif #include <stdio.h> /* definition for sysconf */ #define _POSIX_JOB_CONTROL 1 #define _POSIX_SAVED_IDS 1 #define _POSIX_VERSION 2016L #define _POSIX...
YifuLiu/AliOS-Things
components/posix/include/enviro.h
C
apache-2.0
2,938
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited * * SPDX-License-Identifier: Apache-2.0 */ #ifndef _MQUEUE_H #define _MQUEUE_H #ifdef __cplusplus extern "C" { #endif #include <sys/types.h> #include <time.h> #define DEFAULT_MQUEUE_SIZE 10240 #define DEFAULT_MAX_MSG_SIZE 1024 typedef void *mqd_t; st...
YifuLiu/AliOS-Things
components/posix/include/mqueue.h
C
apache-2.0
1,294
/* * Copyright (C) 2021 Alibaba Group Holding Limited */ #ifndef _POLL_H #define _POLL_H #ifdef __cplusplus extern "C" { #endif #ifndef POLLIN #define POLLIN 0x001 #endif #ifndef POLLOUT #define POLLOUT 0x004 #endif #ifndef POLLERR #define POLLERR 0x008 #endif typedef int nfds_t; struct pollfd { in...
YifuLiu/AliOS-Things
components/posix/include/poll.h
C
apache-2.0
548
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ /* Deprecated, Keep this file only for back compatible in old alios things. * You should use the posix standard header files. */ #ifndef _POSIX_TIMER_H #define _POSIX_TIMER_H #include <time.h> #include <signal.h> #endif
YifuLiu/AliOS-Things
components/posix/include/posix/timer.h
C
apache-2.0
289
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef _PTHREAD_H #define _PTHREAD_H #include <stdint.h> #include <stddef.h> #include <sys/timespec.h> #include <sched.h> #ifdef __cplusplus extern "C" { #endif #define PTHREAD_CREATE_JOINABLE 0 #define PTHREAD_CREATE_DETACHED 1 #define PTHREAD_MUTEX...
YifuLiu/AliOS-Things
components/posix/include/pthread.h
C
apache-2.0
8,120
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef _SCHED_H #define _SCHED_H #ifdef __cplusplus extern "C" { #endif #include <stdint.h> #include <sys/types.h> #include <sys/timespec.h> /* The scheduling policy */ #define SCHED_OTHER 0 #define SCHED_FIFO 1 #define SCHED_RR 2 #define SCHED_C...
YifuLiu/AliOS-Things
components/posix/include/sched.h
C
apache-2.0
792
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef _SEMAPHORE_H #define _SEMAPHORE_H #include <time.h> #ifdef __cplusplus extern "C" { #endif #define SEM_FAILED ((sem_t *)0) #define SEM_VALUE_MAX 32767 typedef struct { void *aos_sem; } sem_t; int sem_init(sem_t *sem, int pshared, unsig...
YifuLiu/AliOS-Things
components/posix/include/semaphore.h
C
apache-2.0
746
/* * Copyright (C) 2015-2021 Alibaba Group Holding Limited */ #ifndef _SIGNAL_H #define _SIGNAL_H #ifdef __cplusplus extern "C" { #endif #include <stdint.h> #include <pthread.h> /* Here is only signal definitions, no signal function is supported. */ #define SIGHUP 1 #define SIGINT 2 #define SIGQUIT 3 #def...
YifuLiu/AliOS-Things
components/posix/include/signal.h
C
apache-2.0
1,668
/* * Copyright (C) 2021 Alibaba Group Holding Limited */
YifuLiu/AliOS-Things
components/posix/include/sys/_pthreadtypes.h
C
apache-2.0
59