Skip to content

Commit ee9d397

Browse files
authored
Merge pull request #20 from CODE-LG/feat/block_screenshot
[FEAT] 화면 캡쳐 방지
2 parents 7b7018a + fdda655 commit ee9d397

9 files changed

Lines changed: 48 additions & 4 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ render.experimental.xml
3333

3434
# Google Services (e.g. APIs or Firebase)
3535
google-services.json
36+
ios/Runner/GoogleService-Info.plist
3637

3738
# Android Profiling
3839
*.hprof

android/app/build.gradle.kts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import java.util.Properties
33
plugins {
44
id("com.android.application")
55
id("kotlin-android")
6+
id("com.google.gms.google-services")
67
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
78
id("dev.flutter.flutter-gradle-plugin")
89
}
@@ -15,7 +16,7 @@ val properties =
1516
android {
1617
namespace = "com.codel.code_l"
1718
compileSdk = flutter.compileSdkVersion
18-
ndkVersion = flutter.ndkVersion
19+
ndkVersion = "27.0.12077973"
1920

2021
compileOptions {
2122
sourceCompatibility = JavaVersion.VERSION_11

android/settings.gradle.kts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ plugins {
2020
id("dev.flutter.flutter-plugin-loader") version "1.0.0"
2121
id("com.android.application") version "8.7.0" apply false
2222
id("org.jetbrains.kotlin.android") version "1.8.22" apply false
23+
id("com.google.gms.google-services") version "4.4.2" apply false
2324
}
2425

2526
include(":app")

ios/Podfile.lock

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,10 @@ PODS:
5656
- kakao_flutter_sdk_common (1.9.7-3):
5757
- Flutter
5858
- RecaptchaInterop (101.0.0)
59+
- screen_protector (1.2.1):
60+
- Flutter
61+
- ScreenProtectorKit (~> 1.3.1)
62+
- ScreenProtectorKit (1.3.1)
5963
- shared_preferences_foundation (0.0.1):
6064
- Flutter
6165
- FlutterMacOS
@@ -65,6 +69,7 @@ DEPENDENCIES:
6569
- firebase_core (from `.symlinks/plugins/firebase_core/ios`)
6670
- Flutter (from `Flutter`)
6771
- kakao_flutter_sdk_common (from `.symlinks/plugins/kakao_flutter_sdk_common/ios`)
72+
- screen_protector (from `.symlinks/plugins/screen_protector/ios`)
6873
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
6974

7075
SPEC REPOS:
@@ -79,6 +84,7 @@ SPEC REPOS:
7984
- GoogleUtilities
8085
- GTMSessionFetcher
8186
- RecaptchaInterop
87+
- ScreenProtectorKit
8288

8389
EXTERNAL SOURCES:
8490
firebase_auth:
@@ -89,6 +95,8 @@ EXTERNAL SOURCES:
8995
:path: Flutter
9096
kakao_flutter_sdk_common:
9197
:path: ".symlinks/plugins/kakao_flutter_sdk_common/ios"
98+
screen_protector:
99+
:path: ".symlinks/plugins/screen_protector/ios"
92100
shared_preferences_foundation:
93101
:path: ".symlinks/plugins/shared_preferences_foundation/darwin"
94102

@@ -107,6 +115,8 @@ SPEC CHECKSUMS:
107115
GTMSessionFetcher: 75b671f9e551e4c49153d4c4f8659ef4f559b970
108116
kakao_flutter_sdk_common: 3dc8492c202af7853585d151490b1c5c6b7576cb
109117
RecaptchaInterop: 11e0b637842dfb48308d242afc3f448062325aba
118+
screen_protector: 6f92086bd2f2f4b54f54913289b9d1310610140b
119+
ScreenProtectorKit: 83a6281b02c7a5902ee6eac4f5045f674e902ae4
110120
shared_preferences_foundation: fcdcbc04712aee1108ac7fda236f363274528f78
111121

112122
PODFILE CHECKSUM: f8c2dcdfb50bb67645580d28a6bf814fca30bdec

ios/Runner.xcodeproj/project.pbxproj

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
1717
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
1818
A95C5CF9F58E465261D3D523 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E6228E8708160B7145026049 /* Pods_Runner.framework */; };
19+
E1FBF0C12DAE7C460017C51F /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = E1FBF0C02DAE7C460017C51F /* GoogleService-Info.plist */; };
1920
/* End PBXBuildFile section */
2021

2122
/* Begin PBXContainerItemProxy section */
@@ -63,6 +64,7 @@
6364
A0C3D7BA37E297BF670F5764 /* Pods-RunnerTests.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RunnerTests.profile.xcconfig"; path = "Target Support Files/Pods-RunnerTests/Pods-RunnerTests.profile.xcconfig"; sourceTree = "<group>"; };
6465
B955AE8AC425CE69815F5900 /* Pods_RunnerTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_RunnerTests.framework; sourceTree = BUILT_PRODUCTS_DIR; };
6566
C7F447F3DE684CF75971C579 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; };
67+
E1FBF0C02DAE7C460017C51F /* GoogleService-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "GoogleService-Info.plist"; sourceTree = "<group>"; };
6668
E6228E8708160B7145026049 /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; };
6769
E771DCC6EFA21C1573E7EC1E /* Pods-RunnerTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RunnerTests.debug.xcconfig"; path = "Target Support Files/Pods-RunnerTests/Pods-RunnerTests.debug.xcconfig"; sourceTree = "<group>"; };
6870
/* End PBXFileReference section */
@@ -105,7 +107,6 @@
105107
70F87F2E741779C30B5DB63A /* Pods-RunnerTests.release.xcconfig */,
106108
A0C3D7BA37E297BF670F5764 /* Pods-RunnerTests.profile.xcconfig */,
107109
);
108-
name = Pods;
109110
path = Pods;
110111
sourceTree = "<group>";
111112
};
@@ -144,6 +145,7 @@
144145
97C146F01CF9000F007C117D /* Runner */ = {
145146
isa = PBXGroup;
146147
children = (
148+
E1FBF0C02DAE7C460017C51F /* GoogleService-Info.plist */,
147149
97C146FA1CF9000F007C117D /* Main.storyboard */,
148150
97C146FD1CF9000F007C117D /* Assets.xcassets */,
149151
97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */,
@@ -262,6 +264,7 @@
262264
files = (
263265
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */,
264266
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
267+
E1FBF0C12DAE7C460017C51F /* GoogleService-Info.plist in Resources */,
265268
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
266269
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
267270
);
@@ -470,15 +473,20 @@
470473
buildSettings = {
471474
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
472475
CLANG_ENABLE_MODULES = YES;
476+
CODE_SIGN_IDENTITY = "Apple Development";
477+
CODE_SIGN_STYLE = Automatic;
473478
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
479+
DEVELOPMENT_TEAM = LRG496B3VQ;
474480
ENABLE_BITCODE = NO;
475481
INFOPLIST_FILE = Runner/Info.plist;
482+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
476483
LD_RUNPATH_SEARCH_PATHS = (
477484
"$(inherited)",
478485
"@executable_path/Frameworks",
479486
);
480487
PRODUCT_BUNDLE_IDENTIFIER = com.codel.codel;
481488
PRODUCT_NAME = "$(TARGET_NAME)";
489+
PROVISIONING_PROFILE_SPECIFIER = "";
482490
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
483491
SWIFT_VERSION = 5.0;
484492
VERSIONING_SYSTEM = "apple-generic";
@@ -652,15 +660,20 @@
652660
buildSettings = {
653661
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
654662
CLANG_ENABLE_MODULES = YES;
663+
CODE_SIGN_IDENTITY = "Apple Development";
664+
CODE_SIGN_STYLE = Automatic;
655665
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
666+
DEVELOPMENT_TEAM = LRG496B3VQ;
656667
ENABLE_BITCODE = NO;
657668
INFOPLIST_FILE = Runner/Info.plist;
669+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
658670
LD_RUNPATH_SEARCH_PATHS = (
659671
"$(inherited)",
660672
"@executable_path/Frameworks",
661673
);
662674
PRODUCT_BUNDLE_IDENTIFIER = com.codel.codel;
663675
PRODUCT_NAME = "$(TARGET_NAME)";
676+
PROVISIONING_PROFILE_SPECIFIER = "";
664677
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
665678
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
666679
SWIFT_VERSION = 5.0;
@@ -674,15 +687,20 @@
674687
buildSettings = {
675688
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
676689
CLANG_ENABLE_MODULES = YES;
690+
CODE_SIGN_IDENTITY = "Apple Development";
691+
CODE_SIGN_STYLE = Automatic;
677692
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
693+
DEVELOPMENT_TEAM = LRG496B3VQ;
678694
ENABLE_BITCODE = NO;
679695
INFOPLIST_FILE = Runner/Info.plist;
696+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
680697
LD_RUNPATH_SEARCH_PATHS = (
681698
"$(inherited)",
682699
"@executable_path/Frameworks",
683700
);
684701
PRODUCT_BUNDLE_IDENTIFIER = com.codel.codel;
685702
PRODUCT_NAME = "$(TARGET_NAME)";
703+
PROVISIONING_PROFILE_SPECIFIER = "";
686704
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
687705
SWIFT_VERSION = 5.0;
688706
VERSIONING_SYSTEM = "apple-generic";

ios/Runner/AppDelegate.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
import Flutter
22
import UIKit
3+
import Firebase
34

45
@main
56
@objc class AppDelegate: FlutterAppDelegate {
67
override func application(
78
_ application: UIApplication,
89
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
910
) -> Bool {
11+
FirebaseApp.configure()
1012
GeneratedPluginRegistrant.register(with: self)
1113
return super.application(application, didFinishLaunchingWithOptions: launchOptions)
1214
}

lib/main.dart

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,19 @@
11
import 'package:code_l/auth/presentation/pages/login/login_page.dart';
2-
import 'package:code_l/sign_up/presentation/pages/code_age/code_age_page.dart';
3-
import 'package:code_l/sign_up/presentation/pages/code_job/code_job_page.dart';
2+
import 'package:firebase_core/firebase_core.dart';
43
import 'package:flutter/material.dart';
54
import 'package:flutter_dotenv/flutter_dotenv.dart';
65
import 'package:flutter_riverpod/flutter_riverpod.dart';
76
import 'package:kakao_flutter_sdk_user/kakao_flutter_sdk_user.dart';
7+
import 'package:screen_protector/screen_protector.dart';
88

99
main() async {
1010
WidgetsFlutterBinding.ensureInitialized();
11+
await Firebase.initializeApp();
1112

1213
await dotenv.load(fileName: ".env");
1314

1415
KakaoSdk.init(nativeAppKey: dotenv.env['KAKAO_NATIVE_APP_KEY']);
16+
await ScreenProtector.preventScreenshotOn();
1517

1618
runApp(const ProviderScope(child: MyApp()));
1719
}

pubspec.lock

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -520,6 +520,14 @@ packages:
520520
url: "https://pub.dev"
521521
source: hosted
522522
version: "2.6.1"
523+
screen_protector:
524+
dependency: "direct main"
525+
description:
526+
name: screen_protector
527+
sha256: "305fd157f6f0b210afe216e790022bfe469c3b1d1f2e0d3dcc5906cc9c49c3e9"
528+
url: "https://pub.dev"
529+
source: hosted
530+
version: "1.4.2+1"
523531
shared_preferences:
524532
dependency: transitive
525533
description:

pubspec.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ dependencies:
4343
http: ^1.3.0
4444
kakao_flutter_sdk_user: ^1.9.7+3
4545
flutter_dotenv: ^5.2.1
46+
screen_protector: ^1.4.2+1
4647

4748
dev_dependencies:
4849
flutter_test:

0 commit comments

Comments
 (0)